Note 1

Take Note:

Take a note while surfing.





Note With Ink

Give your Note a Colorful Tag.




Easy to Access

Stay on same information and in Sync wherever you are.

Note 2

Take Note:

Organize your information,It may take Shape.





Think With Ink

Differ your Content by Color.




Easy to Access

Easy to pull up your content from anywhere anytime.

Note 3

Take Note:

Don't Let information to miss,Because it take shape





Note With Ink

Simple an Easy Way to take a note.




Easy to Access

Get the same in next visit.

C Programming :: Increment-Decrement

Home > C Programming > Increment-Decrement > General Questions

31. What will be output of the following "c" code?

#include
void main ( )
{
int c = --2;
printf("%d" , c);
}

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option B

Explanation:

error: lvalue required as decrement operand

Workspace

Tags:

No Tags on this question yet!

32. What is the output of the following C program?

void main()
{
int i= 0;
while (i<5) {
sum (i);
i++;
} }

void sum (i)
int i;
{
static K;
print{ ("%d",K+i);
K++;
}

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option D

Explanation:

Here is no explanation for this answer

Workspace

Tags:

No Tags on this question yet!

33. The statement i++; is equivalent to

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option A

Explanation:

Here is no explanation for this answer

Workspace

Tags:

No Tags on this question yet!

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option B

Explanation:

Here is no explanation for this answer

Workspace

Tags:

Wipro 

35. Find the output for the following C program

#include
int main()
{
int Y=10;
if( Y++ && Y++!=10 && Y++)
{
printf("%d", Y);
}
else {
printf("%d", Y);
}
return 0;
}

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option B

Explanation:

Here is no explanation for this answer

Workspace

Tags:

Cisco 

36. Find the output for the following C program

#include
int i = 10;
int main()
{
int i =20,n;
for(n=0;n<=i;)
{
int i=10;
i++;
}
printf("%d k", i);
}

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option C

Explanation:

Here is no explanation for this answer

Workspace

Tags:

Cisco 

37. What will be output of following c program?

#include
auto int tcs(int);
int main(){
int a=5;
a=tcs(a);
printf("%d",a);
return 0;
}
auto int tcs(int x){
return x++;
}

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option A

Explanation:

Storage classes allowed with return type are static, extern, typedef.
=> auto and register storage class with the return type of any function

Workspace

Tags:

TCS 

38. What is the value of the following expression?

i = 1;
i << 1 % 2

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option A

Explanation:

Here is no explanation for this answer

Workspace

Tags:

No Tags on this question yet!

39. What is the value of the following expression?

i = 1;
i = (i <<= 1 % 2)

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option B

Explanation:

Here is no explanation for this answer

Workspace

Tags:

No Tags on this question yet!

40. What is the output of the following 'C' program ?

#include
int main()
{
int i=-1;
i<<=2;
printf("%d\n",i);
}

View Answer | Discuss in Forum | Workspace | Asked In |

Answer: Option C

Explanation:

Here is no explanation for this answer

Workspace

Tags:

Global Edge