Write a program which take a integer from user and tell
whether the given variable is squar of some number or not.
eg: is this number is 1,4,9,16... or not
Answer Posted / rajesh kumar
#include<stdio.h>
#include<conio.h>
void main()
{
int a,b;
printf("\n give an integer value");
scanf("%d",&a);
if((a/(a/2))==(a/2))
printf("\n the variable is square of some no");
else
printf("\n the no is not square of some no");
getch();
}
| Is This Answer Correct ? | 2 Yes | 32 No |
Post New Answer View All Answers
Can you apply link and association interchangeably?
How would you rename a function in C?
What is bss in c?
What is f'n in math?
Create a simple code fragment that will swap the values of two variables num1 and num2.
What does the error message "DGROUP exceeds 64K" mean?
the portion of a computer program within which the definition of the variable remains unchanged a) mode b) module c) scope d) none
What is the use of the function in c?
what value is returned to operating system after program execution?
What are register variables? What are the advantage of using register variables?
What are the key features in c programming language?
What is use of bit field?
Is c a great language, or what?
List a few unconditional control statement in c.
we need to calculating INCOME TAX for the person. The INCOME TAX is as follows:- First $10000/- of income : 4% tax Next $10000/- of income : 8% tax Next $10000/- of income : 11.5% tax above $10, 00,00/- : 15% tax What is the Solution of this Question ?