the employee's gross pay. 2. Theater Seating Revenue with Input Validation A dramatic theater has three seating sections, and it charges the following prices tor tickets in each section: section seats cost $20 each, section B seats cost $15 each, and section C seats cost $10 each. The theater has 300 seats in section A, 500 seats in section B, and 200 seats in section C. Design a program that asks for the number of tickets sold in each section and then displays the amount of income generated from ticket sales. The program should validate the numbers that are entered for each section.

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

Question 2

1. Payroll Program with Input Validation
Design a payroll program that prompts the user to enter an employee's hourly pay
rates in the range of $7.50 through $18.25 and hours in the range of 0 through 40
rate and the number of hours worked. Validate the user's input so that only pay
Programming Exercises
Programming Exercises
349
ealivte
Fayroll Program
with Input Valldation
Problem
rates in the range of $7,50 through $18.25 and hours in the range of 0 through 40
are accepted. The program should display the employee's gross pay.
Design a payroll program that prompts the user to enter an employee's nou pay
rate and the number of hours worked. Validate the user's input so that ony40
2. Theater Seating Revenue with Input Validation
A dramatic theater has three seating sections, and it charges the following prices for
tickets in each section: section A seats cost $20 each, section B seats cost $15 eaci,
and section C seats cost $10 each. The theater has 300 seats in section A, 500 seats
in section B, and 200 seats in section C. Design a program that asks for the number
of tickets sold in each section and then displays the amount of income generated
from ticket sales. The program should validate the numbers that are entered for
each section.
3. Fat Gram Calculator
Design a program that asks for the number of fat grams and calories in a food item.
Validate the input as follows:
amc and calories is not less than 0.
Transcribed Image Text:1. Payroll Program with Input Validation Design a payroll program that prompts the user to enter an employee's hourly pay rates in the range of $7.50 through $18.25 and hours in the range of 0 through 40 rate and the number of hours worked. Validate the user's input so that only pay Programming Exercises Programming Exercises 349 ealivte Fayroll Program with Input Valldation Problem rates in the range of $7,50 through $18.25 and hours in the range of 0 through 40 are accepted. The program should display the employee's gross pay. Design a payroll program that prompts the user to enter an employee's nou pay rate and the number of hours worked. Validate the user's input so that ony40 2. Theater Seating Revenue with Input Validation A dramatic theater has three seating sections, and it charges the following prices for tickets in each section: section A seats cost $20 each, section B seats cost $15 eaci, and section C seats cost $10 each. The theater has 300 seats in section A, 500 seats in section B, and 200 seats in section C. Design a program that asks for the number of tickets sold in each section and then displays the amount of income generated from ticket sales. The program should validate the numbers that are entered for each section. 3. Fat Gram Calculator Design a program that asks for the number of fat grams and calories in a food item. Validate the input as follows: amc and calories is not less than 0.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 4 steps with 3 images

Blurred answer
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
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr