i
isn’t an index. It is the value itself. So your if
is trying to check if(arr[7])
, if(arr['ate'])
, etc.
1 Like
i
isn’t an index. It is the value itself. So your if
is trying to check if(arr[7])
, if(arr['ate'])
, etc.