Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

This is a C++ coding problem I have been having issues with the past couple days I was wondering If you could write the source

This is a C++ coding problem I have been having issues with the past couple days I was wondering If you could write the source code and send it to me ? I will take pictures of what it is what the program has to do and what I have so far!
image text in transcribed
image text in transcribed
image text in transcribed
image text in transcribed
image text in transcribed
,-. ||Normal !No Spac- Heading 1 Heading 2 Title Subtitle Styles Paragraph Solve This C++ Coding problem and send me the source code? Hotel Booking The cost of renting a room at our hotel is $100.00 per night for Standard Rooms and $150.00 for the top floor Penthouse Rooms. There are only 20 Penthouse rooms total The sales tax is 6% 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 10, the discount is 10% at least 20, the discount is 20% o o o o o and at least 30, the discount is 30%. Also if rooms are booked for at least 3 days, then there is an additional 596 o discount. If the number of rooms booked happens to be a prime number then there will be an additional Nerd Discount of 7%. These discounts must be explicitly mentioned in your output Non Iterative Prime Numbers For Nerd Discount: o o .The first 11 prime integers are 2, 3, 5, 7,11, 13, 17, 19, 23, 29, and 31. A positive integer between 1 and 1000 (inclusive), other than the first 11 prime integers, is prime if it is not divisible by 2, 3, 5,7, 11, 13, 17, 19, 23, 29, and 31. .What I want you to do here is to write an algorithm that will apply the discount if the number of rooms is not evenly divisible by any number in the list: 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, and 31. You can determine divisibility using modulus division with a check for a remainder of O I want you to write this algorithm using a compound boolean condition and logical operators. This means a single if statement containing all of the ||Normal ||No Spac.. ,-. 2-_. Heading 1-Heading 2 Title Subtitle Paragraph Styles tests, joined together using&&, or II (whatever is appropriate) NOTE: I will be testing for prime numbers that are NOT in this list and you are not allowed to simply write an enormous if statement testing for all prime numbers up to 1000. You may only use the list given to calculate whether.or.not a number is prime. Write a program that prompts the user to enter o The type of room requested (Standard or Penthouse) o the number of rooms requested o the number of days the rooms are booked o the type of occasion. Only ask this question if the number of rooms requested is 10 or more Things to include If the user wants Penthouse rooms, but requests more than 20 then the program should o charge for 20 Penthouse rooms and the remainder as Standard Rooms The program will then output The occasion, if any o o The number of rooms o Whether or not the rooms are Standard or Penthouse, or Both (see "Things to Include ) o The number of days requested o The total cost of the booking BEFORE any discounts are applied o An itemized list of ALL discounts applied and the monetary amounts of each o The discounted charge o The amount of sales tax o The total cost for the booking o The output should be directed to a file and meet the following formatting requirements. I will be grading this strictly Sample output Occasion: Number of Rooms: Room Type: Conference 47 Standard Wl AaBbCcDd AaBbCcDd | L Normal 2- . :-. 2--. 1 No Spac Heading 1-Heading 2 . Titi Paragraph Style o o o o o An itemized list of ALL discounts applied and the monetary amounts of each The discounted charge The amount of sales tax The total cost for the booking The output should be directed to a file and meet the following formatting requirements. I will be grading this strictly Sample output Occasion: Conference Number of Rooms: Room Type: Days... Total Charge$4700.00 More than 30 Room Discount:... Nerd Discount:.. 47 Standard $1410.00 $329.00 Sales Tax: Total Charge:$3138.66 $177.66 Sample output for different case Number of Rooms: Room Type:Penthouse 4 Days Total Charge: $1200.00 Sales Tax 2 $76.00 Total Charge:$1276.00 | main() : int int Roomrequested 0 ; int Daysrequested 0 string occassionType double total-0 cout> Roomrequested ; if (Roomrequested Roomtype 24 llit (Roomtype !-"Standard" Roontype '-"Penthouse") 25 26 27 cout Daysrequested if (Roomtype "Standard") cout

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions