Answer to Question #30811 in C++ for princeyawar

Question #30811
Write a program that calculates square and cube of numbers from 15 to 25.
1
Expert's answer
2013-05-24T09:06:06-0400
#include <stdio.h>
int main () {
for (int i = 15; i <= 25; i++)
printf("number %d:\nsquare: %d\ncube: %d\n\n", i, i * i, i * i * i);
return 0;
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
APPROVED BY CLIENTS