the thing is.. i need to read a text file
[code=cpp]
<matrix>
rows = 2
cols = 2
1 2
2 4
</matrix>
[/code]
and i need to store the data in a double array [10][10]..
where the matrix max size is 10 by 10...
also i nid to extract the values of rows and cols and save it to row and col variables..
i got a suggestion to use strtok()..
but i am not sure how to do so...
could someone tell me how in relation my problem above?
thanks in advance
[code=cpp]
<matrix>
rows = 2
cols = 2
1 2
2 4
</matrix>
[/code]
and i need to store the data in a double array [10][10]..
where the matrix max size is 10 by 10...
also i nid to extract the values of rows and cols and save it to row and col variables..
i got a suggestion to use strtok()..
but i am not sure how to do so...
could someone tell me how in relation my problem above?
thanks in advance
Comment