:     A tea company sells a box of tea that retails for $15. A 20% quantity discount is given for purchasing 10 or more boxes of tea. Write a program that asks the user to enter the number of tea boxes purchased. The program should then display the amount of the discount (if any) and the total amount of the purchase after the discount.     The area of a rectangle is the rectangle's length times its width. Write a program that asks for the length and width of two rectangles. The program should tell the user wh

Programming Logic & Design Comprehensive
9th Edition
ISBN:9781337669405
Author:FARRELL
Publisher:FARRELL
Chapter6: Arrays
Section: Chapter Questions
Problem 9PE
icon
Related questions
Question

Submit the Python code and the program design (pseudocode or flowchart) for each of the following questions:

    A tea company sells a box of tea that retails for $15. A 20% quantity discount is given for purchasing 10 or more boxes of tea. Write a program that asks the user to enter the number of tea boxes purchased. The program should then display the amount of the discount (if any) and the total amount of the purchase after the discount.

    The area of a rectangle is the rectangle's length times its width. Write a program that asks for the length and width of two rectangles. The program should tell the user which rectangle has a greater area.

 

 

 

Expert Solution
steps

Step by step

Solved in 2 steps with 2 images

Blurred answer
Knowledge Booster
Program on Numbers
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
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage