Part B: Draw Something   In this portion of the lab you will draw an inverted triangle using loops. ********** ********* ******** ******* ****** ***** **** *** ** *  Part B: Draw Something New! Write a complete and syntactically correct Python program to solve the following problem:  You want to write a program that will take in the number of grades of the students in your class.  Since the students in a class vary from semester to semester, there is no fixed number assigned to the number of students.  You will keep track of how many students’ grade you input.  You will stop taking input when the student enters a grade of minus 1 (-1). Your program will use loops and will accomplish the following: Read in a numeric grade from a student Convert the numeric grade to a letter grade using the grade policies in your syllabus. Keep a running total of the numeric grades entered. Keep a count of the number of grades entered. Issue a message that comments on the letter grade earned. As an example, you may write “You made an F! Obviously you did not study!” At the end of the program calculate a class average unless there were NO grades entered.   All input to the program will be interactive from the keyboard.  The output of the program will include the individual grades converted, the message issued to the student, a class average, and the number of grades entered.

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter8: Arrays
Section: Chapter Questions
Problem 8PE
icon
Related questions
Question

For this portion of the lab, you will reuse the program you wrote in Lab 3A.  Redesign this solution so that some portions of the code are repeated.  In lab 3 you validated input to ensure that the user entered inputs within certain values.  If the user entered an invalid value, the program terminated.  Now you will add a loop such that the user gets three changes to enter a valid value.  If the user enters an invalid value more than three times in a row, the program should issue an error message and terminate.

 

  1. Save the program as firstname_lastname_Lab4a.py where you will replace firstname and lastname with your actual first and last name.
  2. Test all conditions prior to submitting. If the user enters an invalid value, then the program will issue an error message and terminate immediately. (Do NOT accept further data).

Part B: Draw Something

 

In this portion of the lab you will draw an inverted triangle using loops.

**********

*********

********

*******

******

*****

****

***

**

*

 Part B: Draw Something New!

Write a complete and syntactically correct Python program to solve the following problem:

 You want to write a program that will take in the number of grades of the students in your class.  Since the students in a class vary from semester to semester, there is no fixed number assigned to the number of students.  You will keep track of how many students’ grade you input.  You will stop taking input when the student enters a grade of

minus 1 (-1).

Your program will use loops and will accomplish the following:

  1. Read in a numeric grade from a student
  2. Convert the numeric grade to a letter grade using the grade policies in your syllabus.
  3. Keep a running total of the numeric grades entered.
  4. Keep a count of the number of grades entered.
  5. Issue a message that comments on the letter grade earned. As an example, you may write “You made an F! Obviously you did not study!”
  6. At the end of the program calculate a class average unless there were NO grades entered.

 

All input to the program will be interactive from the keyboard.  The output of the program will include the individual grades converted, the message issued to the student, a class average, and the number of grades entered.

Use the IDLE programming

python

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 2 images

Blurred answer
Knowledge Booster
Types of Loop
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
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,