I'm starting in python
and always end up with some doubts in the beginning.
I need to know how to test if a list
is empty.
As I always say, I come from PHP.
So I used to do these forms:
count($array) == 0
empty($array);
!$array
How to do this in python
?
Example:
a = [1, 2, 3]
b = []
# a é vazio?
# b é vazio?