Hello
I want to put into a struct three numbers from a text file
in which each number is in different line. I tested fgets to read line by line, but i cant think an efficient way to read three integers each time
For example
struct nums
{ int x,y,z; }
nums1={1,2,3} nums2={4,5,6}
text file:
1
2
3
4
5
6
I want to put into a struct three numbers from a text file
in which each number is in different line. I tested fgets to read line by line, but i cant think an efficient way to read three integers each time
For example
struct nums
{ int x,y,z; }
nums1={1,2,3} nums2={4,5,6}
text file:
1
2
3
4
5
6