Question: Please write the program in C + + Programs: Write a program that prompts the user to enter four integer values and reads the four

Please write the program in C++ Programs:
Write a program that prompts the user to enter four integer values and reads the four values with separate scanf statements. Write statements to find the square of each value. Print the values and their squares in a labeled table aligned as in the example shown below (note: the data in the table below is not the numbers you should be submitting, it's just an example). Use five lines of output statements. Test your program with 5,3,9, and 4
\table[[Number,Squared],[2,4],[4,16],[6,36],[8,64]]
HINT: Your output will require 5 printf statements. One to print the headers of the columns. Then one for each line of data. If you use the same formatting for each placeholder, then the columns will all line up. The four lines of code should be identical, except for the variable names.
Please write the program in C + + Programs: Write

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 Programming Questions!