reading a .txt file which contains names with numbers

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Mattp
    New Member
    • Nov 2006
    • 1

    reading a .txt file which contains names with numbers

    hi:
    I have a .txt file that contains a persons name, their id number, and mark average.
    can someone show me a sample c++ code that opens the file and reads it. i guess i have to use vectors for this assignment but i'm not sure how to do it.

    filename= class.txt

    bob Simmons --->name
    1234------------>id number
    67.8------------->average mark

    Jane Doe
    678
    82.5
  • sivadhas2006
    New Member
    • Nov 2006
    • 142

    #2
    Hi,

    Can you post your code, whatever you have tried to solve the problem?

    Regards,
    M.Sivadhas.

    Comment

    Working...