PROGRAM TO FIND SQUARE OF A NUMBER USING FUNCTIONS

/*PROGRAM TO FIND SQUARE OF A NUMBER USING FUNCTIONS*/
#include<stdio.h>
#include<conio.h>
int sqre(int);
void main()
{
int n,s;
clrscr();
printf(“Enter any number: “);
scanf(“%d”,&n);
s=sqre(n);
printf(“Square of given number is:%d”,s);
getch();
}
int sqre(int a)
{
return(a*a);
}

Leave a Reply

Your email address will not be published. Required fields are marked *