Read in from a file with specific syntax …

Home Forums C Programming Read in from a file with specific syntax …

This topic contains 1 reply, has 2 voices, and was last updated by  Humayan 11 years ago.

  • Author
    Posts
  • #2044

    toton
    Member

    Hello, thank you for taking the time to review my problem. I’m trying to read in from a file which has specific syntax (shown below) and recognize part1 and part2. It should compare part1 with an internal value to be returned from later code. In short:
    The file will consist of the following:
     
    part1:part2
    etc…
     
    I need to read each line and recognize part1 as a variable and part2 as a variable (seperated by the colon, which is to be ignored). If I can get that working, I have the rest sorted out (i think). All feedback is greatly appreciated!!

  • #3292

    Humayan
    Member

    Heres an old program that I have that reads an int then a float on each line:
     

You must be logged in to reply to this topic.

Share
Tweet
Share
Pin
+1