C Operators Questions and Answers
Practice ModeShowing 10 of 122 questions
Q101
Find the output
void main ( )
{
unsigned int i=2;
i=(((i<<6)-1)^127||(i+3>>3));
printf("%u",i);
}
Answer: Option B
Q102
Find the output
void main ( )
{
int i=1;
i= i + 2*i++ + -i;
printf ("i is now %d", is);
}
Answer: Option A
Q103
Find the output
void main ( )
{
int x=10;
printf(5d %d %d", x==10, x=20, x<20);
}
Answer: Option C
Q104
Find the output
void main( )
{
int a=3, b=4, c;
c=b==4||a!=3;
printf ("%d", c}
}
Answer: Option B
Q105
Find the output
void main ( )
{
int a, b, c, d, e;
e=++a&&++b||--c&&d++;
printf("%d",e);
}
Answer: Option B
Q106
Find the output
void main ( )
{
int a=2, b=6, c=5;
c*=a+b;
printf ("%d", c);
}
Answer: Option C
Q107
Find the output
printf ("5s", #CAcademy);
Answer: Option C
Q108
Find the output
void main ( )
{
int i=-1, j=-1, k=0, 1=2, m;
m=i++&&j++&&k++||1++;
printf("%d %d %d %d", i,j,k, 1,m);
}
Answer: Option B
Q109
Find the output
void main ( )
{
int a=5, b=6, c=2, d;
d=(a++, ++b, c++);
printf("%d%d%d",d,a,ac);
}
Answer: Option A
Q110
Unary operators are
Answer: Option A