How to copy a string to array string spare with space?
Thank you !
string ="TOM MARY PETER JOHN";
change to
*s[0] = "TOM"
*s[1] = "MARY"
*s[2] = "PETER"
*s[3] = "JOHN"
can anyone give me an example? thx!!
Printable View
How to copy a string to array string spare with space?
Thank you !
string ="TOM MARY PETER JOHN";
change to
*s[0] = "TOM"
*s[1] = "MARY"
*s[2] = "PETER"
*s[3] = "JOHN"
can anyone give me an example? thx!!
look up strtok() in your help files.
thx!!~