Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

6) Write a C++ program that asks the user to input two numbers. If the first number entered is greater than the second number the

image text in transcribed
6) Write a C++ program that asks the user to input two numbers. If the first number entered is greater than the second number the program should print the message The first number is greater" else it should print the message The first number is smaller" Test your program for the numbers 5 and 8, and then using 11 and 2. What happens if the two numbers are equal? 7) write a C++ program that displays either the message"PROCEED WITH TAKEOFF, or "ABORT TAKEOFF" depending on the input. If the character g is entered in the variable code, the first message should be displayed; otherwise the second message should be displayed 8) Write a program that accepts two real numbers from a user and a select code. If the entered select code is a, have the program add the two previously entered numbers and display the result; if the select code is b, the numbers should be multiplied, and if the select code is e, the first number should be divided by the second number What will happen if the numbers entered are 3 and 0, and the select code is c. Modify the program so that division by 0 is not allowed and an appropriate m displayed when such a division is attempted. Part C

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_2

Step: 3

blur-text-image_step3

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