Ah, that's what it was! "%[^\n]". Now I know. :)
Usually one thread about one program is sufficient . . .Quote:
For my personal culture I'll post a new thread and if no one know, I'll take your idea.
Printable View
Ah, that's what it was! "%[^\n]". Now I know. :)
Usually one thread about one program is sufficient . . .Quote:
For my personal culture I'll post a new thread and if no one know, I'll take your idea.
I was wondering already how the regexp [^ ] would have worked in this situation, since it is interpreted as "everything not a space". The correct version, the one you posted, is interpreted as "everything not a new line char" which makes more sense :)
Yes, I don't know what I was thinking. :)
By the way, when I read the numbers in my float, I would like that my sscanf dosn't ad 0 like he does (when I display my float, he show me 40.000000 instead of 40.0000) or (850.50000 instead of 850.5000). Can I use sscanf just to display the exact number while staying a float. (If there is no way I'll just print a string and after put him as a float to use this number later in my program)
Your issue is with printf, not sscanf.