Write a void function that reads a file “a:data.txt” with up to 35 student ids, names and final marks into 3 arrays. When the student name is "quit" stop processing or if 35 array elements have been read then stop processing . The function should return the length of the actual number of students as well as the 3 arrays. In main, show all declarations and show the actual call. You can use the following prototype and data file: (note that in this case length would be 4) const int SIZE = 35; void ReadData( string name[],int id[], int mark[], int& length); data.txt Bob 123456 89 Suki 234567 77 Felix 345678 55 Julie 456789 67 quit in c++ please use basic coding I'm not advanced

C++ for Engineers and Scientists
4th Edition
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Bronson, Gary J.
Chapter8: I/o Streams And Data Files
Section8.3: Random File Access
Problem 6E
icon
Related questions
Question

Write a void function that reads a file “a:data.txt” with up to 35 student ids, names and final marks into 3 arrays.  When the student name is  "quit"  stop processing or if  35 array elements have been read then stop processing .  The function should return the length of the actual number of students as well as the 3 arrays.   In main, show all declarations and show the actual call.

You can use the following prototype and data file: (note that in this case length would be 4)

const int SIZE = 35;

void ReadData( string name[],int id[], int mark[], int& length);

 data.txt                                                           

Bob     123456            89

Suki     234567            77

Felix    345678            55       

Julie     456789            67

quit 

 

in c++ please use basic coding I'm not advanced

Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
File Input and Output Operations
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage