Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Q4.(20 points) Note: You do not have to write the entire program, just give the

ID: 3596396 • Letter: Q

Question

Q4.(20 points) Note: You do not have to write the entire program, just give the code segment in i)For the variables declared below, write a statement using the object cin that wil pause 'he computer so the user can type the appropriate data. a. char ch1, ch2; b. float temp1, temp2, temp3 ii)write appropriate if statement for each of the following conditions a. If an angle is equal to 90 degrees print the message "The angle is a right angle" otherwise print the message "The angle is not a right angle.

Explanation / Answer

Solution:

i)

a)

char ch1, ch2;

cout<<"Please enter ch1";

cin>>ch1;

cout<<"Please enter ch1";

cin>>ch2;

b)

cout<<"Please enter the value of temp1";

cin>>temp1;

cout<<"Please enter the value of temp2";

cin>>temp2;

cout<<"Please enter the value of temp3";

cin>>temp3;

ii)

if(angle == 90)

cout<<"The angle is a right angle";

else

cout<<"The angle is not a right angle";

Please, please upvote and ask your doubts in the comments.