Skill set for this LAB:
Problem 2
:
Write a program that finds total cost of
shopping cart and average price per item.
You buy the following items: milk, bread, and prepared chicken.
Input: number of milk bottles, price per bottle,
number of bread loafs, price per loaf, number of prepared chickens,
price of
prepared chicken, and the tax. ONLY PREPARED FOOD
is taxable
Problem 3: :
The final grade in our course is
calculated according to the following rule:
Laboratory Sessions | 45% |
Exams | 35% |
Mini-Quizzes | 15% |
Homework and Attendance | 5% |
Examples - use these examples to TEST your program
Problem 5 :
A treasure box has a 4-digit combination lock. The box opens when you enter
the following value: (sum of middle digits)*(average of first and last
digit). Write a program that reads one 4-digit number, combination lock, and
finds the number that opens the box.
Problem
6 :
Most savings accounts offer interest to keep your money growing. Write a
program that reads initial deposit into saving account and interest rate per
year (as integer). The program finds and prints the amount you will have in
the saving account after one year.
Problem
7 :
Write a program that prompts the user to enter one positive 4 digits
integer. The program will do the following: if the input number is even, the
program will print the digits of the number in the reverse order, and if the
input number is odd, the program will calculate the sum and the product of
the digits and prints the result with the appropriate message. Hint: An even
number is an integer that is "evenly divisible" by 2, i.e., divisible by 2
without remainder i.e., remainder = 0
Problem
8 :
Most online shopping websites offer free shipping if you spend certain
amount of money. Write a program that reads the following information: the
purchase amount before tax, free shipping rule (the smallest amount of
dollars consumer must spend to receive a free shipping), the tax
percent(integer), and flat shipping charges. We will assume that the
shipping charges are always the same and shipping charges ARE TAXABLE. The
program will calculate and prints the total price of your purchase. For
example: macys.com offers free shipping if you spend 99 dollars and more, so
if you will spend 50 dollars, and the shipping charges are 3.99, and your
state tax is 7%, the total price will be: $57.77 For example: target.com
offers free shipping if you spend 50 dollars or more, so if you will spend
$99.99, and the shipping charges are 5.99, and your state tax is 6%, the
total will be $105.99