1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Anika [276]
3 years ago
6

Write a Python program calculate summary statistics about a class assignment. First, prompt the user for the number scores to be

entered. Then prompt for each score, re prompting for values outside the range 0 - 100. Finally, display the minimum, maximum and average scores. There is no need to keep a list of scores, they you may do so if you wish. Use good, meaningful variable names.

Computers and Technology
1 answer:
In-s [12.5K]3 years ago
3 0

Answer:

see explaination

Explanation:

Code:

count = 0 num_of_sub = int(input("Enter a number of subjects : ")) marks_of_subjects = [] for i in range(num_of_sub): count = count + 1 while True: marks = int(input("Enter the marks for subject {} : ".format(count))) if marks < 0 or marks > 100: print("Marks are out of range: Try again") else: marks_of_subjects.append(marks) break Total = sum(marks_of_subjects) Min_marks = min(marks_of_subjects) Max_marks = max(marks_of_subjects) Average_marks = sum(marks_of_subjects)/len(marks_of_subjects) print("Total Marks in the exams are {} Marks".format(Total)) print("Minimum Score in the exam is {} Marks".format(Min_marks)) print("Maximum Score in the exam is {} Marks".format(Max_marks)) print("Average Score in the exam is {:.2f} Marks".format(Average_marks))

see attachment for the screenshot and output

You might be interested in
Which of the following would most likely be the target audience for a product
inna [77]

Answer:

B

Explanation:

They are saturday morning cartoons. Saturday morning cartoons are meant towards an audience of young children.

3 0
3 years ago
Read 2 more answers
Which science topics would be suited for this organizational aid? Check all that apply.
IrinaVladis [17]

Answer:

Its A and E

Explanation:

3 0
2 years ago
#include
gavmur [86]

Answer:

See explaination

Explanation:

#include <fstream>

#include <iostream>

#include <iomanip>

using namespace std;

int main()

{

// Fill in the code to define payfile as an input file

ifstream payfile;

float gross;

float net;

float hours;

float payRate;

float stateTax;

float fedTax;

cout << fixed << setprecision(2) << showpoint;

// Fill in the code to open payfile and attach it to the physical file

// named payroll.dat

payfile.open("payroll.dat");

// Fill in code to write a conditional statement to check if payfile

// does not exist.

if(!payfile)

{

cout << "Error opening file. \n";

cout << "It may not exist where indicated" << endl;

return 1;

}

ofstream outfile("pay.out");

cout << "Payrate Hours Gross Pay Net Pay"

<< endl << endl;

outfile << "Payrate Hours Gross Pay Net Pay"

<< endl << endl;

// Fill in code to prime the read for the payfile file.

payfile >> hours;

// Fill in code to write a loop condition to run while payfile has more

// data to process.

while(!payfile.eof())

{

payfile >> payRate >> stateTax >> fedTax;

gross = payRate * hours;

net = gross - (gross * stateTax) - (gross * fedTax);

cout << payRate << setw(15) << hours << setw(12) << gross

<< setw(12) << net << endl;

outfile << payRate << setw(15) << hours << setw(12) << gross

<< setw(12) << net << endl;

payfile >> hours ;// Fill in the code to finish this with the appropriate

// variable to be input

}

payfile.close();

outfile.close();

return 0;

}

4 0
3 years ago
How would you create a tint of a color?
svetlana [45]
D. white with a hue
HOPE THIS HELPS
5 0
2 years ago
How to take a key off a keyboard without breaking it?
klio [65]
You can carfully wedge something in between the key and gently pull up 
4 0
3 years ago
Other questions:
  • A musical compact disc is an example of
    13·1 answer
  • Your organization will be handling market trades. You will be required to verify the identify of each customer who is executing
    8·1 answer
  • Whenever I go onto Google Chrome, the words are in Spanish! How can I make the words be back in English again? Please let me kno
    7·1 answer
  • :If a process terminates, will its threads also terminate or will they continue to run? Explain your answer.
    14·1 answer
  • The _____ dialog box lets you specify which files are to be merged.
    14·1 answer
  • Recently, your laptop won't power on, and the battery is not charging. You suspect the block on the power cord (also known as a
    5·1 answer
  • String[][] arr = {{"Hello,", "Hi,", "Hey,"}, {"it's", "it is", "it really is"}, {"nice", "great", "a pleasure"},
    11·1 answer
  • Tier 1 networks form the internet ____.​
    15·1 answer
  • PLEASE HELP WILL MARK BRAINLIEST
    8·2 answers
  • Which native windows application allows you to access basic pc settings and controls such as system information, controlling use
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!