Question: ty ploject 18r Each programming question. Q. 01 (2 points) Write an iflelse statement that assigns 0 to x when y is equal to 10.

 ty ploject 18r Each programming question. Q. 01 (2 points) Write
an iflelse statement that assigns 0 to x when y is equal
to 10. Otherwise it should assign 1 to x. Q.02 (2 points)
Write an if statement that prints the message "The number is not
valid" if the variable hours is outside the range 0 through 80
Q. 03 (4 points) Convert the following iflelse if statement into a

ty ploject 18r Each programming question. Q. 01 (2 points) Write an iflelse statement that assigns 0 to x when y is equal to 10. Otherwise it should assign 1 to x. Q.02 (2 points) Write an if statement that prints the message "The number is not valid" if the variable hours is outside the range 0 through 80 Q. 03 (4 points) Convert the following iflelse if statement into a switch statement: if (choice1) cout 20) b. The following statement should determine if count is within the range of 0 through 100. What is wrong with it? if (count >-011 coun 100) Q. 05 (3 points) Write a do-while loop that asks the user to enter two numbers. The numbers should be added and the sum displayed. The user should be asked if he or she wishes to perform the operation again. If so, the loop should repeat; otherwise it should terminate. Q. 06 (2 points) Convert the following while loop to a do-while loop: int x = 1; while (x > 0) cout>x Q.07 (2 points) Convert the following while loop to a for loop: int count while (count

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!