It seems that you are confusing the value of 'c' with the value in the array.



char arr[4] = {9, 8, 7, 6};
int c;

for (c=0; c <= arr[c]; c++} ...