plz solve this in C. don't copy other people's code. thanks You are in charge of planning a holiday party for your organization at a venue nearby, which meant that you have to organize the details including food and activities. After researching the possibilities, you have considered three packages. Each package charges a minimum fee for the first hour of room rental, and an additional fee every hour in excess of the first hour. The maximum duration possible for reserving per day is 4 hours. There is a maximum charge for room rental for an event. Write a program that calculates and prints the total charge for a selected package, the duration, and food and activities (based on the number of people attending). Package First Hour of room rental (minimum) Hourly Cost after the First Hour Maximum room rental charge for an event Minimum number of guests Maximum number of guests Cost per person for food and activities #1 $50 $25 $95 50 200 $25 #2 $30 $15 $55 80 300 $22 #3 $20 $12 $40 30 150 $20 Requirements The user enters the package selection, enter the number of hours, and number of people. The program calculates and prints the charge. Follow the format of the examples below. Your program should validate the package selection. If the selection is not in the range of 1 to 3, print the message "Invalid selection. Select from 1 to 3." and exit the program. Your program should validate the hours rented. If the number entered is less than 1 or great than 4, print the message "Invalid input. Enter a positive number less than or equal to 4 for number of hours." and exit the program. Your program should validate the number of people. If the number of people entered is less than the minimum number of guests or greater than the room capacity for the package selected, print a message ("Not meeting minimum requirement for number of guests." or "Exceeded maximum number of guests.") and exit the program. Examples (your program must follow this format precisely) Example #1 Please select from three packages: 1, 2, and 3 Enter package selection: 1 Enter hours: 3 Enter number of people: 200 Charge($): $5095 Example #2 Please select from three packages: 1, 2, and 3 Enter package selection: 2 Enter hours: 4 Enter number of people: 100 Charge($): $2255 Example #3 Please select from three packages: 1, 2, and 3 Enter package selection: 10 Invalid selection. Select from 1 to 3.
plz solve this in C. don't copy other people's code. thanks
You are in charge of planning a holiday party for your organization at a venue nearby, which meant that you have to organize the details including food and activities. After researching the possibilities, you have considered three packages.
Each package charges a minimum fee for the first hour of room rental, and an additional fee every hour in excess of the first hour. The maximum duration possible for reserving per day is 4 hours. There is a maximum charge for room rental for an event.
Write a
Package |
First Hour of room rental (minimum) |
Hourly Cost after the First Hour |
Maximum room rental charge for an event |
Minimum number of guests |
Maximum number of guests |
Cost per person for food and activities |
#1 |
$50 |
$25 |
$95 |
50 |
200 |
$25 |
#2 |
$30 |
$15 |
$55 |
80 |
300 |
$22 |
#3 |
$20 |
$12 |
$40 |
30 |
150 |
$20 |
Requirements
The user enters the package selection, enter the number of hours, and number of people. The program calculates and prints the charge. Follow the format of the examples below.
Your program should validate the package selection. If the selection is not in the range of 1 to 3, print the message "Invalid selection. Select from 1 to 3." and exit the program.
Your program should validate the hours rented. If the number entered is less than 1 or great than 4, print the message "Invalid input. Enter a positive number less than or equal to 4 for number of hours." and exit the program.
Your program should validate the number of people. If the number of people entered is less than the minimum number of guests or greater than the room capacity for the package selected, print a message ("Not meeting minimum requirement for number of guests." or "Exceeded maximum number of guests.") and exit the program.
Examples (your program must follow this format precisely)
Example #1
Please select from three packages: 1, 2, and 3
Enter package selection: 1
Enter hours: 3
Enter number of people: 200
Charge($): $5095
Example #2
Please select from three packages: 1, 2, and 3
Enter package selection: 2
Enter hours: 4
Enter number of people: 100
Charge($): $2255
Example #3
Please select from three packages: 1, 2, and 3
Enter package selection: 10
Invalid selection. Select from 1 to 3.

Trending now
This is a popular solution!
Step by step
Solved in 5 steps with 6 images









