c - Parsing an array of chars -


let's have "game.abc" string (array of chars) , want chars before dot. deem efficient way in c?

is "while until . copy char char" way go or there other way?

i hope question can others also.

thanks!

you can use strchr() followed strncpy() find first instance of '.' in string , copy characters before string


Comments

Popular posts from this blog

Add email recipient to all new Trac tickets -

400 Bad Request on Apache/PHP AddHandler wrapper -

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -