Get sizeof individual array member

I need to get the length of each string within an array of strings.
Following code just returns 2 for each line.
Any suggestions?

#define NUMLINES 4

char *lines[NUMLINES] = 
 "The way back\t",
 "Space Fall\t",
 "Cygnus Alpha\t",
 "Time Squad\t"  

void setup() 

 for(int i = 0 ; i < NUMLINES; i++)

void loop(void){}


Please edit your post, select the code, and put it between [code][/code] tags.

You can do that by hitting the “Code” button above the posting area (It looks like a scroll with < > inside it).

Following code just returns 6 for each line.

Not on my Uno it doesn't:

The way back    2
Space Fall  2
Cygnus Alpha    2
Time Squad  2

Ok 2 then.

Point is its the same value.


Ok 2 then.

Point is its the same value.


Because… That is not an array of strings, it is an array of pointers to strings, and a pointer, in AVR, is two bytes.

Ray L.

If you want the length of the strings, use strlen.

Thank you Nick,

Been a while since i used C.

You have saved my sanity.

Regards, Mark