main()
{
int i,j,A;
for(A=-1;A<=1;A++)
prinf("%d\t",!!A);
}
Answers were Sorted based on User's Feedback
Answer / ashwin kumar
sorry friends one small mistake in above explanation
hi friends
in c we must know one thing 1st
any number other than '0' is taken as true in c language
so as A=-1 1st
so A is true
now not of A i.e !A = false=0
now not of !A i.e !!A= true =1
so 1st 1 is printed
same if u do for A=0
it will be false 1st than true than false
i.e 0 is printed
for A=1 same as A=-1
there fore answer is 101
| Is This Answer Correct ? | 5 Yes | 0 No |
Answer / ashwin kumar
hi friends
in c we must know one thing 1st
any number other than '0' is taken as false in c language
so as A=-1 1st
so A is true
now not of A i.e !A = false=0
now not of !A i.e !!A= true =1
so 1st 1 is printed
same if u do for A=0
it will be false 1st than true than false
i.e 0 is printed
for A=1 same as A=-1
there fore answer is 101
| Is This Answer Correct ? | 2 Yes | 2 No |
How will you find a duplicate number in a array without negating the nos ?
cavium networks written test pattern ..
print ur name 20,000 times without using inbuilt library functions like printf,scanf,gets,puts,getchar or putchar
Write a c program to build a heap method using Pointer to function and pointer to structure ?
How many types of errors are there in c language? Explain
diff between exptected result and requirement?
7. Identify the correct argument for the function call fflush() in ANSI C: A)stdout B)stdin C)stderr D)All the above
What is a nested formula?
What is a structure member in c?
What is the difference between break and continue?
Why we use void main in c?
Why should I use standard library functions instead of writing my own?