MATLAB: Isempty is allways zero

isempty

Hello,
im using isempty:
TP =
0 0 0
>> isempty(TP)
ans =
logical
0
>> TP(3) = 1
TP =
0 0 1
>> isempty(TP)
ans =
logical
0
Why is locical answer still zero? What can I do? I need to check multiple arrays for empty or not in if-else blocks.

Best Answer

zero and empty are different
isempty([])
isempty(0)
isempty('')