Question
Python program A Camping EXPO has admission fees of $17.00 for adults, $8 for children 6-12 years old, and $2.00 for children under 6. A
Python program
A Camping EXPO has admission fees of $17.00 for adults, $8 for children 6-12 years old, and $2.00 for children under 6. A student just starting as a novice Python program is working for the Camping EXPO to write an introductory level program that will get from the keyboard the number of adults (numAdults), children 6-12 years old (numChildren6_12), and children under 6 years old (numChildrenUnder6) who attended the Camping EXPO. The program will then use each of the fees as magic numbers (constants): ADULT_FEE = 17.00 CHILD_6_12_FEE = 8.00 CHILD_UNDER_6_FEE = 2.00
along with numAdults, numChildren6_12, numChildrenUnder6 to compute the total number of attendees (totalAttendees) and the total fees (totalFees) collected.
The program then outputs at the screen the following numAdults numChildren6_12 numChildrenUnder6 totalAttendees totalFees, formatted to two digits to the right of the decimal point, including the commas in a user-friendly fashion. Below, for example, is the expected fashion for the output for data that I ran for my program. This program uses data from the keyboard for the number of adults, children 6 through 12, and children under 6 who attend a Camping EXPO. The admissions fees for adults is $17.00, children 6 through 12 $8.00, and children under 6 $2.00. The program displays this information at the screen along with the total number of attendees at the Camping EXPO, and the total fees collected at the EXPO.
How many adults attended?125
How many children 6-12 attended?43
How many children under 6 attended?21
The number of adults attending the EXPO is 125
The number of children (6-12) attending the EXPO is 43
The number of children under 6 attending the EXPO is 21
The total number of attendees at the Camping EXPO is 189
The total fees collected at the Camping EXPO is $2,511.00
Make sure that you include (1) a description of the program to the reader and (2) a description of the program to the user at the screen.
what to expect in the program
Description of Program to the reader
Description of Program to the user
Magic numbers (constants) are defined as required for ADULT_FEE, CHILD_6_12_FEE, and CHILD_UNDER_6_FEE
Correctly prompted for and read from the keyboard numAdults, numChildren6_12, and numChildrenUnder6
Correctly computes the total number of attendees and the total fees collected at the event
Correctly displays at the screen the results including the number of adults, number of children 6-12, number of children under 6, total number of attendees at the event, and the total fees collected at the event. The total fees displayed must show commas and two digits to the right of the decimal point
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started