Professional Documents
Culture Documents
Chapter 3 : Modules
A. Stadium Seating
There are three seating categories at a stadium. For a softball game, Class A seats cost 1500, Class B
seats cost 1300, and Class C seats cost 1000. Design a modular program that asks how many tickets
for each class of seats were sold, and then displays the amount of income generated from ticket
sales.
PSEUDOCODE
FLOWCHART
import ticketsales
print (ticketsales)
A painting company has determined that for every 120 square feet of wall space, one gallon of paint
and eight hours of labor will be required. The company charges 40.00 per hour for labor. Design a
modular program that asks the user to enter the square feet of wall space to be painted and the
price of the paint per gallon. The program should display the following data:
PSEUDOCODE
FLOWCHART
def painting():
num_square_foot = int(input('Enter square feet to be painted: '))
price_gall = float(input('Enter price per gallon of paint: PHP '))
totality(num_square_foot, price_gall)
painting()
import PAINTBi
print (PAINTBi)