C Program to print table of n and square of n using pow() Function
Posted by Samath
Last Updated: January 02, 2017

Write a C program that will print table of n and square of n using the pow() function. 

Code:

#include<stdio.h>
#include<conio.h>
#include<math.h>

int main()
{
      
      printf("Table Square\n");
      printf("-----------------\n");
      for(int n=1;n <=10;n++){
      	printf("\n%d\t%.0f",n,pow(n,2));
      }
          
      return 0;
}