sscanf2 Explode String
#1

Hi.
How can i explode my string with sscanf2 ? Any example?

I have this string: "AAAA - BBBB - CCC DDDD" . I want explode "-" this key
So i must get "AAAA" , "BBBB", "CCC DDDD"

Sorry for english. Please help
Reply
#2

https://github.com/Y-Less/sscanf/wik...ced-Delimiters
Reply
#3

Код:
sscanf(InputString, "p<->s[size]s[size]", output1, output2);
p<> (it defines delimiter character, you can set it to , . - | or whatever you like...
Reply
#4

Thanks a lot, but when i use the sscanf, strings remove spaces.
Example AAA-BBB- CCC
not get " CCC". sscanf gives "CCC" for last one. Why remove spaces?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)