Question: Problem 2 : Write a C + + program that prompts the user to enter an integer. Using if / else statements, classify and print

Problem 2: Write a C++ program that prompts the user to enter an integer. Using if/else statements, classify and print the type of the number based on the following criteria: Positive, Negative, Zero, Even, Odd.
Example: for input 5 the output should be: The number is positive and odd.
Problem 3: Write a program that prompts the user to enter a number between 1 and 12. Based on the number entered, use a switch statement to print the corresponding month name (e.g.,1 for January, 2 for February, etc.). If the number entered is outside the valid range, print an error message.
 Problem 2: Write a C++ program that prompts the user to

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!