Answered step by step
Verified Expert Solution
Question
1 Approved Answer
PLEASE USE VISUAL STUDIO C + + . The cost of renting a room at a hotel is , say $ 1 0 0 .
PLEASE USE VISUAL STUDIO C
The cost of renting a room at a hotel is say $ per night. For special occasions, such as a wedding or conference, the hotel offers a special discount as follows:
If the number of rooms booked is at least the discount is ; at least the discount is ; and at least the discount is
Also, if rooms are booked for at least three days, then there is an additional discount.
Write a program that
reads the daily room rate and the sales tax rate from the input file provided below inputdat and
prompts the user to enter the number of rooms booked and the number of days the rooms are booked.
The program outputs to an output file named output.dat
the cost of renting one room,
the discount on each room as a percent,
the number of rooms booked, the number of days the rooms are booked,
the total cost of the rooms,
the sales tax, and
the total billing amount.
Your output should be neat and professional. Below is an example output.dat file your file should look similar but with your own values where the example has #s
Your program must use appropriately named constants to store special values such as the various discounts.
INPUT.DAT file
OUTPUT.DAT
Cost of renting one room : #####
Discount rate per room : ###
Number of rooms booked: ###
Number of days booked: ###
Total cost of the rooms $: ######
Sales tax $: ####
Total billing amount $: ######
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