Question: ( 1 6 pts ) Ch 9 - - # 3 2 ( people . dat is posted in Canvas ) A program is being

(16pts)Ch9--#32(people.dat is posted in Canvas)
A program is being written to store and manipulate information on some people,
including their name, height (in feet and inches, both integers), and weight in pounds.
This information is stored in a file named people.dat. Each line in the file stores
the information for one person; there is one blank space between each piece of
information in the file. For example, the file might look like this:
Sammie 510182
Richard 65222.5
In your main script, for this problem, you should read this information in, store it in a
vector of structures, and then print it out. (For now, error-checking on the file open
and close has been omitted for simplicity.) Write a parseline function that will
take each line from the file and return a structure in the required format. For example,
if the file is as shown above, the result from your main script would be:
Sammie is 5'10" tall and weighs 182.0 pounds
Richard is 6'5" tall and weighs 222.5 pounds

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!