using scanf and family to read in two strings separated by a space from a file in c -


i trying read in 2 string separated space file.

whatever try keep getting 1st string initialized second string null.

some of formatters have tried "%s%s" , "%s %s" , "%s[\n\t ]%s"

any ideas of doing wrong?

i think has internal buffer of scanf -- reads first %s puts invisible character in buffer reads 2nd %s read , second string null when complete.

what strings like?

i don't think hypothesis of fscanf() modifying input data placing "some invisible character in buffer" true.

it seems more strings don't conform requirements of %s format specifier.


Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -