Absolute C++
Absolute C++
6th Edition
ISBN: 9780133970784
Author: Walter Savitch, Kenrick Mock
Publisher: Addison-Wesley
bartleby

Concept explainers

bartleby

Videos

Textbook Question
Book Icon
Chapter 2, Problem 7PP

Write a program that calculates the total grade for N classroom exercises as a percentage. The user should input the value for N followed by each of the N scores and totals. Calculate the overall percentage (sum of the total points earned divided by the total points possible) and output it as a percentage. Sample input and output are shown as follows:

How many exercises to input? 3

Score received for exercise 1 : 10

Total points possible for exercise 1: 10

Score received for exercise 2: 7

Total points possible for exercise 2 : 12

Score received for exercise 3: 5

Total points possible for exercise 3 : 8

Your total is 22 out of 30, or 73.33 % .

Blurred answer
Students have asked these similar questions
Write a program that calculates the total grade for N classroom exercises as a percentage. The user should input the value for N followed by each of the N scores and totals. Calculate the overall percentage (sum of the total points earned divided by the total points possible) and output it as a percentage. Sample input and output is shown below. How many exercises to input? 3 Score received for exercise 1: 10 Total points possible for exercise 1: 10 Score received for exercise 2: 7 Total points possible for exercise 2: 12 Score received for exercise 3: 5 Total points possible for exercise 3: 8 Your total is 22 out of 30, or 73.33%.
The average cost of a college textbook is $125. There is a premium of 20% on hardcover text and a discount of 5% on sales of more than 4 textbooks. Write a program to prompt the user for the appropriate inputs and compute and display the before-tax cost of the textbooks.Sample calculation:price of 10 hardcover text = 10 * 125 + premium –discountprice = 1250 + 20% of 1250 – 5% of 1250price = $1437.50price of 8 softcover text = 8 * 125 –discountprice = 1000 – 5% of 1000price = $950price of 2 softcover text = 2 * 125price = $250
Question 1 Write a program that asks the user to enter the number of passengers in an airplane and the weight of baggage for these passengers. Your program should then print the average weight of all baggage; it should also print the weights in reverse order. Sample run: Enter the number of passengers in the airplane: 8 Enter the weights of 8 baggage: 16 45 60 13 24 29 50 30 The average weight of all baggage is 33.375 The entered weights in reverse order are 30 50 29 24 13 60 45 16

Additional Engineering Textbook Solutions

Find more solutions based on key concepts
Knowledge Booster
Background pattern image
Computer Science
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
Text book image
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Text book image
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Text book image
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
Text book image
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Text book image
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Text book image
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education
Constants, Variables, Data types, Keywords in C Programming Language Tutorial; Author: LearningLad;https://www.youtube.com/watch?v=d7tdL-ZEWdE;License: Standard YouTube License, CC-BY