Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

(Use PYthon program please )idle 64 A teacher wants to be able to enter test scores and find the average. She would like to have

(Use PYthon program please )idle 64

A teacher wants to be able to enter test scores and find the average. She would like to have a feature

that allows her to remove the last test score added if she miss typed it. For example:

The test scores 98, 65, 89, 77, 16 were entered one at a time pressing the Enter key after each

one. The teacher realized that the 16 was supposed to be 61 and wants to remove the 16 and

replace it with the 61.

Write a program that uses the Stack class created in class that will hold the test scores until the teacher

enters DONE. If the teacher enters a number, it should be pushed onto the stack. If the teacher enters

REVERSE, the last number entered should be removed. After all the numbers have been entered, the

program should calculate the average and display the following:

The test scores entered listed on one line separated by a comma

The average of the test scores

The letter grade for the student Grading scale A is 90 or more, B is 80 89, C is 70 79, D is 60

69 and F is below 60.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Databases Illuminated

Authors: Catherine M. Ricardo, Susan D. Urban, Karen C. Davis

4th Edition

1284231585, 978-1284231588

More Books

Students also viewed these Databases questions

Question

Brief the importance of span of control and its concepts.

Answered: 1 week ago

Question

What is meant by decentralisation?

Answered: 1 week ago

Question

Write down the Limitation of Beer - Lamberts law?

Answered: 1 week ago