Last week I was able to go see the new Dr. Strange movie. I thought it was pretty awesome. When I was looking at buying

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

Last week I was able to go see the new Dr. Strange movie. I thought it was pretty awesome. When I was looking at buying

Post by answerhappygod »

Last week I was able to go see the new Dr. Strange movie. I thought it was pretty awesome. When I was looking at buying tickets I wanted to make sure I got as many discounts as I could. By default a movie ticket is 15$. If you go before 5 pm, the ticket price is 12.50$. If you plan on buying in bulk(5 or more tickets) you will recieve a 10% discount. If you are a student, you get a 15% discount.
Write a program that asks the user if they are going to the movie before 5pm(1 for yes, 0 for no), how many tickets they are going to buy (an integer greater than 1) and if they are a student(1 for yes, 0 for no). Print out the total cost for the amount of tickets you would like to buy.
Last Week I Was Able To Go See The New Dr Strange Movie I Thought It Was Pretty Awesome When I Was Looking At Buying 1
Last Week I Was Able To Go See The New Dr Strange Movie I Thought It Was Pretty Awesome When I Was Looking At Buying 1 (415.5 KiB) Viewed 38 times
Last Week I Was Able To Go See The New Dr Strange Movie I Thought It Was Pretty Awesome When I Was Looking At Buying 2
Last Week I Was Able To Go See The New Dr Strange Movie I Thought It Was Pretty Awesome When I Was Looking At Buying 2 (508.04 KiB) Viewed 38 times
could get. By default a movie ticket is $15. If you go before 5pm, the ticket price is $12.50. If you plan on buying in bulk (5 or more tickets) you will receive a 10% discount. If you are a student, you get a 15% discount. Write a program that asks the user if they are going to the movie before 5PM ( 1 for yes, 0 for no), how many tickets they are going to buy (an integer greater than 1), and if they are a student ( 1 for yes, 0 for no). Print out the total cost for the amount of tickets you would like to buy. Sample Case 1: Are you going to the movie before 5PM? (1 - Yes, 0 - No) 0 How many people are going? 2 Are you a student? (1 - Yes, 0 - No) 0 The group's price is $30.00. Sample Case 2: Are you going to the movie before 5PM? (1-Yes, 0 -No) 1 How many people are going? 1 Are you a student? (1 - Yes, 0 - No ) 1 The group's price is $10.62. " If you are getting 10.63 this is also correct. The way you round does not matter. Sample Case 3: Are you going to the movie before 5PM? (1 - Yes, 0 - No)
Are you a student? (1− Yes, 0 - No ) 0 The group's price is $30.00 Sample Case 2: Are you going to the movie before 5PM ? (1 - Yes, 0 - No ) 1 How many people are going? 1 Are you a student? (1 - Yes, 0 - No ) 1 The group's price is $10.62. If you are getting 10.63 this is also correct. The way you round does not matter. Sample Cage 3: Are you going to the movie before 5PM?(1−Yes,0 - No ) 0 How mamy people are going? 5 Are you a student? (1 - Yes, 0−No) 1 The group's price is $57,37.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply