Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

PLEASE completw the following in C language Name Student ID: Section: (5 MARKS] a Write, compile, and run a C program to do the following:

PLEASE completw the following in C language image text in transcribed
image text in transcribed
Name Student ID: Section: (5 MARKS] a Write, compile, and run a C program to do the following: N A theatre charges half admission price (of $14.25) on Tuesdays and is free on Sundays. On all other days of the week, the regular admission price is $28.50 per ticket. LE S at 11 2 3 4 5 6 77 8 9 12 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 A school is planning for multiple admissions to this theatre on different days of the week. If the total cost for all the admissions exceeds $800, a message "Total cost exceeds permitted budget" should be printed. The user of the program specifies the day of the week and the number of students. The program is to calculate the total price of admission to the theatre as follows: total admission cost number of students admission ticket price. The day of the week is specified by a single character as follows: 'M' or m' Monday T' or 't' Tuesday 'W' or 'W' Wednesday 'R' or '' Thursday 'F' or 'F' Friday 'S' or 's Saturday 'U' or 'u' Sunday ut use 5. slu uti You are to complete the program so that the program produces results similar to that shown in the sample run below! a r NOTE: The Name, Student ID and Section that appears in the output of the program should be your own, not the ones used in the sample run ord 35 36 37 30 39 Sample run 1: inc lut Name: Smith, Peter Student ID: 300999999 Section: 001 43 42. 43 ma 45 46 47 48 49 5e 51 Using the following scheme: 'M' or Monday 'T' or 't Tuesday 'W' or '' Wednesday Ror " - Thursday Forf - Friday '5' or 's' = Saturday "U" or "U = Sunday I 100% No issues found Global Scope 44 45 45 Using the following scheme: More Monday "Tort Tuesday Wor Wednesday R or Thursday For Friday S' or s Saturday U' or 'u Sunday Enter the day of the weeket M Number of students: 17 149 50 51 52 53 54 55 50 57 50 59 60 61 Total cost exceeds permitted budget Press any key to continue PROGRAM OUTPUT - Provide Foul sample runs and paste it to your WORD document For the FTST sample run: Enter M for day of the week and 17 for the number of students. For the SECOND sample run Entert for day of the week and for the number of students For the THTID sample run Enter Ufor day of the week and 42 for ther of students, - For the FOURTH sample run Enter for day of the week and 25 for the number of students 07 mmunn include include int main() ""). return

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored 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

Recommended Textbook for

Oracle Database Administration The Essential Reference

Authors: Brian Laskey, David Kreines

1st Edition

1565925165, 978-1565925168

More Books

Students also viewed these Databases questions

Question

107 MA ammeter 56 resistor ? V voltmeter

Answered: 1 week ago