- #1
Leonardo Machado
- 57
- 2
Hello friends, how are you ?
Today's question is: How do i choose the data i want to extract from a file in c++ ?
I have this data file in columns format, something like:
I know there is the command file.getline() , and this command can be manipulated to get the string the size i want, but there is a way of skip the space between the numbers and catch only the data of the second column?
And plus, there are any way to get it not in str format ? but in a float or a double format ?
Thanks for the tips
Today's question is: How do i choose the data i want to extract from a file in c++ ?
I have this data file in columns format, something like:
Code:
x y z
1 2 3
4 5 6
7 8 9
I know there is the command file.getline() , and this command can be manipulated to get the string the size i want, but there is a way of skip the space between the numbers and catch only the data of the second column?
And plus, there are any way to get it not in str format ? but in a float or a double format ?
Thanks for the tips