Question: **** has to be done using C++ please **** **** C++ **** Exercise 5 Cash Register: Ask the user to enter the total amount (in

**** has to be done using C++ please **** **** C++ ****

**** has to be done using C++ please **** **** C++ ****Exercise 5 Cash Register: Ask the user to enter the total amount

Exercise 5 Cash Register: Ask the user to enter the total amount (in CAD) of the purchased items. 2. Ask the user to enter the total amount (in CAD) paid by the customer 3. Now, the program should display the exact number of bills to be returned to the customer. Example: Enter the total amount of the bill: 326 Enter the amount paid by the customer: 405 You should return to the customer the following: 100S bills: 0 20S bills: 3 10$ bills: 1 5S bills: 1 1S coins: 4 Exercise 3 Factorial: Read an integer N from the user then display the factorial of this number, N!. Note that, the factorial of a negative number is undefined. In case the user enters a negative number, the program should notify the user and then ask him to enter a positive number instead. Recall that. N, = N * (N-1)* (N-2)* * 2 * 1 Example: Please enter a positive number: 6 The factorial of 6 is: 6!-720 Exercise 4 Product of first N odd numbers: Read an integer N from the user then display the product of all odd numbers smaller than or equal to N (if N is even, it should not be included in the product). Example Please enter a positive number: 7 The product of all odd numbers smaller than or equal to 7 is 1*3*5*7 = 105 Example: Please enter a positive number:6 The product of all odd numbers smaller than or equal to 6 is 113*5 = 15

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!