- Section D Writing Code 10 Marks Write The Code To Implement The Following Write The Function Int Loadhighscores As 1 (89.17 KiB) Viewed 72 times
Section D: Writing Code [10 marks] Write the code to implement the following: Write the function: int LoadHighScores (AS
-
- Posts: 43759
- Joined: Sat Aug 07, 2021 7:38 am
Section D: Writing Code [10 marks] Write the code to implement the following: Write the function: int LoadHighScores (AS
Section D: Writing Code [10 marks] Write the code to implement the following: Write the function: int LoadHighScores (AScore Score Table, int Length, char *Filename); that opens the file Filename and reads the contents into the array of structures ScoreTable that has Length elements. If there are more than Length entries in the file Filename, you should only read Length elements. If there are less than Length entries in the file Filename, you should fill the remaining elements with default placeholder entries. The format of the structure AScore is: #typedef { char Name[21]; char Planet[21]; int Fuel; int Score;} AScore;