StayTalentReady

Exercises — Outcome 8: File Input and Output

1 hands-on tasks. Do them in order; each one feeds the Canvas item it names.

30 min · hands-on

1. Grade File Logger

  1. Write a program that asks the user for their name and three test scores.
  2. Write the data to a file named 'grades.txt' with one entry per line in format: Name, Score1, Score2, Score3.
  3. Write a second program that reads 'grades.txt', calculates the average for each student, and prints the results.
Turn in / bring: Both Python scripts and the contents of grades.txt submitted to Canvas.
← Outcome 7Outcome 9 →

↑ Back to top