# Answer to Question #13088 in C++ for rochielle quita

Question #13088

problem:

write a program to list the numbers from 0 to 25, their squares, and square roots. the output should be in a neat three-column format. use the predifined functions sr and sqrt.

write a program to list the numbers from 0 to 25, their squares, and square roots. the output should be in a neat three-column format. use the predifined functions sr and sqrt.

Expert's answer

#include "stdafx.h"

#include <stdio.h>

#include

<math.h>

#include <conio.h>

#include

<iostream>

using namespace std;

int main()

{

double

resultsqrt,powresult;

cout<<"Number Squares Square

roots\n";

for(double

i=0;i<=25;i++){

resultsqrt=sqrt(i);

powresult=pow(i,2);

cout<<i<<"

"<<powresult<<"

"<<resultsqrt<<""<<"\n";

}

getch();

return

0;

}

#include <stdio.h>

#include

<math.h>

#include <conio.h>

#include

<iostream>

using namespace std;

int main()

{

double

resultsqrt,powresult;

cout<<"Number Squares Square

roots\n";

for(double

i=0;i<=25;i++){

resultsqrt=sqrt(i);

powresult=pow(i,2);

cout<<i<<"

"<<powresult<<"

"<<resultsqrt<<""<<"\n";

}

getch();

return

0;

}

Need a fast expert's response?

Submit orderand get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

## Comments

Assignment Expert16.02.17, 16:11Dear visitor,

please use panel for submitting new questions

Polly Williams16.02.17, 00:03This function is the entry point of the entire program. It takes two arguments: a)

An input number (e.g 124), b) A threshold number (e.g. 0.01). It should first use the math

library to calculate the square root and output its result. Then it should use your square

root function and output the results in each step.

## Leave a comment