What is the result
main()
{
char c=-64;
int i=-32
unsigned int u =-16;
if(c>i){
printf("pass1,");
if(c<u)
printf("pass2");
else
printf("Fail2");}
else
printf("Fail1);
if(i<u)
printf("pass2");
else
printf("Fail2")
}
a)Pass1,Pass2
b)Pass1,Fail2
c)Fail1,Pass2
d)Fail1,Fail2
e)none
Answer Posted / vikraman85
u should not assign a negative value to unsigned int! b'coz
it has only +ve values 0to2^15-1..
| Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
Why do we use c for the speed of light?
What is #include called?
What is the general form of #line preprocessor?
Write a code to generate divisors of an integer?
How would you use the functions fseek(), freed(), fwrite() and ftell()?
Is c programming hard?
Can you please explain the difference between exit() and _exit() function?
What is a program?
What does void main () mean?
Why is %d used in c?
Why malloc is faster than calloc?
What are dangling pointers in c?
Explain what is #line used for?
Do pointers take up memory?
Is return a keyword in c?