39.2k views
0 votes
how can I write a program that calculates and produces these 2 columns sequence numbers using looping statement.​

User Rantiev
by
7.3k points

1 Answer

4 votes

Answer:

#include <stdio.h>

int main() {

for (int i = 1; i <= 10; i++) {

printf("%d\t%d\\", i, i*i);

}

return 0;

}

OUTPUT

1 1

2 4

3 9

4 16

5 25

6 36

7 49

8 64

9 81

10 100

User Manoj Kumawat
by
7.7k points