If you are talking about Python's actual array
(available through import array from array
), then the principle of least astonishment applies and you can check whether it is empty the same way you'd check if a list is empty.
from array import array
an_array = array('i') # an array of ints
if an_array:
print("this won't be printed")
an_array.append(3)
if an_array:
print("this will be printed")