Question: Do program7 , using c++ and printf and scanf , not cin and cout. For full credit on each program, please paste your output to
For full credit on each program, please paste your output to the comment and comment. Also please make sure to format your output properly X Program 1: Write a C program which will allow the user to enter in two integers and will print out the two integers, the sum, difference, product, quotient (a cast will be needed), modulus, and average (a cast will be needed) of the two integers xProgram 2: You need a program to maintain information about grocery items. Assume that you have the following grocery items: Item Name Cereal Chocolate CandySnickers Mik Bananas Brand |Quantity Unit Price |Discount % Yum Yum Cereal $6.19 $1.99 $4.89 6.4% 928% 5.72% 12.15% Have A Cow Chiquita 15 Write a C program that will perform the following tasks: Task 1: Allow the user to enter in the data for each grocery item. (The user will not enter the S or % symbols) Task 2: For each grocery item, calculate the cost, discount amount, and the cost with discount. The formulas to use are as follows: Cost Unit Price Quantity Discount Amount-Cost , Discount % / 100 Cost With Discount Cost- Discount Amount Task 3: Print out the item name for each grocery item followed by the results of your three calculations from Task 2 four of the grocery items Program 3: Rewrite Program 2 by calculating the discount % to use for each grocery item. e and print the total cost, the total discount amount, and the total cost with discount for all The user will Use the following discount percentages: no longer enter the discount % from the keyboard. Discount% Quantity 1 to 3 4 to 7 8 to 12 More than 12 3.8% 5.1% 7.4% 9.8%
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
