Reference no: EM13165295
This code should include a loop that displays income generated from ticket sales for each night. Shows are performed on Thursday, Friday and Saturday nights.
int main()
{
int A, B, C;
int TotalIncome;
cout << "Enter number of seats sold in Section A: \n";
cin >> A;
cout << "Enter number of seats sold in Section B: \n";
cin >> B;
cout << "Enter a number of seats sold in Section C: \n";
cin >> C;
while (A < 0 or A > 300)
{
cout << "ERROR: Seats sold in Section A cannot be \n";
cout << "greater than 300 or negative.\n ";
cout << "Enter valid value for seats sold in section A: \n";
cout << "A value in the range of 0 to 300 inclusive. \n";
cin >> A;
}
while (B < 0 or B > 500)
{
cout << "ERROR: Seats sold in Section B cannot be \n";
cout << "greater than 500 or negative.\n ";
cout << "Enter valid value for seats sold in section C: \n";
cout << "A value in the range of 0 to 500 inclusive. \n";
cin >> B;
}
while (C < 0 or C > 200)
{
cout << "ERROR: Seats sold in Section C cannot be \n";
cout << "greater than 200 or negative.\n ";
cout << "Enter valid value for seats sold in section C: \n";
cout << "A value in the range of 0 to 200 inclusive. \n";
cin >> C;
}
TotalIncome = (A * 20) + (B * 15) + (C * 10);
cout << "The total income generated from ticket sales \n ";
cout << "of all sections is $ " << TotalIncome;
}
Ticketmaster
: TICKETMASTER - this class will have: a service charge = $8.00 per ticket, tax = .085 current amount of all tickets sold. Its responsibilities are printing a list of events for sale, looking up an event for a customer, and selling a ticket to the e..
|
Binary scientific notation
: For IEEE 754 single precision floating point, what is the number, as written in binary scientific notation, whose hexadecimal representation is: 0061 0000
|
America and the great war
: The assassination of Archduke Franz Ferdinand was the immediate cause of World War I. But the events that led to the Great War go further back into the nineteenth century. As with the Boxer Rebellion of 1900, nationalism, imperialism, and militarism ..
|
Write the hexadecimal representation for -1.0
: For IEEE 754 single precision floating point, write the hexadecimal representation for -1.0
|
Code should include a loop that displays income
: This code should include a loop that displays income generated from ticket sales for each night. Shows are performed on Thursday, Friday and Saturday nights.
|
Implements both the quicksort and mergesort algorithms
: Write a program that correctly implements both the Quicksort and Mergesort algorithms. The program should generate an array of 500 random numbers in the 1-100 range. The program should sort the same set of numbers and keep time stamps of how long it ..
|
How to link different classes forms
: How to link different classes forms. When a person clicks on A, B, or C the program will go to the addEmployee form or Punch In/Out form in Java.
|
While loop that allows the user to continue entering
: This code should include a while loop that allows the user to continue entering employees as long as they want to continue:int main(){Real payrate,hours, gross,again;
|
E easy to process in a cobol variable-length record
: Which would be easy to process in a COBOL variable-length record or fixed-length record?
|