Guest_imported
New member
- Jan 1, 1970
- 0
#include <stdio.h>
#include <math.h>
void main()
{
int x, y, z;
/* example */
x = 36;
y = 49;
z = (x + y) * (x + y ); /*these 2 calculations will */
/* produce the same result,*/
z = pow(x+y,2); /* is this the correct way to use */
/* pow()and is it valid in ANSI C */
printf(" The value of z is %d",z);
}
thanks
#include <math.h>
void main()
{
int x, y, z;
/* example */
x = 36;
y = 49;
z = (x + y) * (x + y ); /*these 2 calculations will */
/* produce the same result,*/
z = pow(x+y,2); /* is this the correct way to use */
/* pow()and is it valid in ANSI C */
printf(" The value of z is %d",z);
}
thanks