Suppose a file.txt contains : 50 40 30 # # 5 # 10 # #

i want to fetch only integers. How should i fetch it. I tried with fgetc 
and fscanf but it was too complicated.

My approach: fetched one word at a time and put it into separate string and 
then i converted that string to integer(if each character of that string 
was between '0' to '9').

Is there any simple way to do this. 
 

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/algogeeks/-/btvudXnBrAIJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to