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 / madhuri
here int i=-32 is not terminated so syntax error
if that statement was terminated then the answer would be
none in the given options because the output of the program
would be
pass1
pass2
pass2
Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
What is the equivalent code of the following statement in WHILE LOOP format?
What are the different types of control structures?
Write a C program in Fibonacci series.
Write a C program that will accept a hexadecimal number as input and then display a menu that will permit any of the following operations to be carried out: Display the hexadecimal equivalent of the one's complement. (b) Carry out a masking operation and then display the hexadecimal equivalent of the result. (c) Carry out a bit shifting operation and then display the hexadecimal equivalent of the result. (d) Exit. If the masking operation is selected, prompt the user lor the type of operation (bitwise and, bitwise exclusive or, or bitwise or) and then a (hexadecimal) value for the mask. If the bit shifting operation is selected. prompt the user for the type of shift (left or right), and then the number of bits. Test the program with several different (hexadecimal) input values of your own choice.
How would you use the functions fseek(), freed(), fwrite() and ftell()?
What is abstract data structure in c?
What are valid operations on pointers?
What is the function of this pointer?
When a c file is executed there are many files that are automatically opened what are they files?
Which of the following operators is incorrect and why? ( >=, <=, <>, ==)
What is the difference between array and linked list in c?
Can the sizeof operator be used to tell the size of an array passed to a function?
What is the maximum length of an identifier?
Can stdout be forced to print somewhere other than the screen?
How can I determine whether a machines byte order is big-endian or little-endian?