Please written by computer source 1, 2 C++ Programming. Please answer ASAP. Thank you very much.

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

Please written by computer source

1, 2 C++ ProgrammingPlease answer ASAP. Thank you very much.

Question 1: Write a C++ program that reads two marks (a mark for mathematic course and another mark for physics course) and the weighting of the mark of mathematics compared to that of physics. The program then displays the weighted average with two obligatory decimals. Below is the example of how the program should look like.

Enter average in math 80.25 Enter the average in physics 100 Enter the weight assigned to mathematics 0.4 The weighted average is then 92.10%

2) Write a C++ program that asks for the different prices for a bus ticket (adult, child, senior). Then, the program asks for the number of adults, elders, and children in the group. The program then displays the total ordered without taxes. Then the program displays the amount of the provincial tax (9.975% of the total Canadian price without tax) and federal tax (5% of the Canadian price total without tax) as well as the total sum including taxes. See the following example of output:

Enter the ticket price for adults: 3.75 Enter the ticket price for children: 1.75 Enter the price of the ticket for seniors: 1.25 Enter the number of adults in your group: 2 Enter the number of children in your group: 3 Enter the number of seniors in your group: 2 The total price to be paid excluding tax is 15.25 dollars The provincial tax to pay is 1.52 dollars The federal tax to pay is 0.76 dollars The amount of all tickets is 17.53 dollars

Expert Solution
steps

Step by step

Solved in 3 steps with 4 images

Blurred answer
Knowledge Booster
Introduction to Coding
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
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education