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 :: C Preprocessor

Home > C Programming > C Preprocessor > General Questions

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

#define FALSE -1
#define TRUE 1
#define NULL 0
int main()
{
if(NULL)
puts("NULL");
else if(FALSE)
puts("TRUE");
else
puts("FALSE");
return 0;
}

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!

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

#include
#define swap(a,b,c) c = a; a = b; b = c;
int main()
{
int a = 3,b = 5;
int temp;
swap(a,b,temp)
printf("%d %d %d\n",a,b,temp);
}

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

Answer: Option C

Explanation:

Here is no explanation for this answer

Workspace

Tags:

No Tags on this question yet!

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

#include
#define swap(a,b,c) c = a; a = b; b = c
int main()
{
int a = 3,b = 5;
int temp;
swap(a,b,temp);
printf("%d %d %d\n",a,b,temp);
}

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!

14. What are the values printed by the following program?

#define dprint(expr) printf(#expr "=%d\n",expr)

main()
{
int x=7;
int y=3;
dprintf(x/y);
}

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

Answer: Option C

Explanation:

Here is no explanation for this answer

Workspace

Tags:

Wipro 

15. Preprocessor does not do which one of the following

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

Answer: Option C

Explanation:

Here is no explanation for this answer

Workspace

Tags:

Wipro 

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

#include
#define SQR(x) x*x
void main()
{
int a =5, b, c;
b = SQR(a++);
c = SQR(++a);
printf("%d %d", b, c);
}

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

Answer: Option C

Explanation:

Here is no explanation for this answer

Workspace

Tags:

No Tags on this question yet!

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

#include
#define a 10
void main( )
{
#define a 50
printf("%d",a);
}

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!

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

#include
#define SQR(a) a*a
void main ()
{
int x = 5, y;
y = 25/SQR(x);
printf("%d", y);
}

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!

19. What is the value of variable POLYGON?

void main ()
{
int POLYGON, L, B;
L = B = 2;
POLYGON= (L = = B)? 1:0;
}

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!

20. # define max (x, y)x = (x > y)? x : y is a macro definition.
Which can find the maximum of two numbers x and y if

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!