/* Square root of a number without using square root function */
main()
{
int num;
int temp, temp1;
num = 144;
temp = num/2; temp1 = 0;
while( temp != temp1)
{
temp1 = temp;
temp = (num/temp + temp)/2;
}
printf ("square root of a number : %d\n", temp);
}