Given a file with the results from a game of bowling, calculate the final score
ID: 3532974 • Letter: G
Question
Given a file with the results from a game of bowling, calculate the final score and report the results to an output file. I do not have to control bad input from file and all numbers will be legal to the game of bowling.
We have not learned arrays yet so I'm trying to do this program without them.
Text file it reads in looks like this:
10
7 3
7 2
9 1
10
10
10
2 3
6 4
7 3 3
Then the output to the screen and to an output file should look like this:
1 2 3 4 5 6 7 8 9 10
Player X 7/ 7 2 9/ X X X 2 3 6/ 7/3
Score 20 37 46 66 96 118 133 138 155 168
Explanation / Answer
ask me if any doubt. and please do rate this.
------------------------------------------------
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.