But when i output data it doesn't seem to work, can you help with that?
What seems to be the problem?
You do realize that you have more data on each line that you are not trying to retrieve, right?
Also please show a small complete program that illustrates your problem, and don't forget to show what the program is outputting and what you think it should be outputting.
By the way why are you trying to retrieve a bunch of numbers into a bunch of strings?