What is the difference between #define and constant in C?A #define is used as immediate constant or as a macro. Where as the constant is a variable whose value can not change.
Pointer can be declared to a constant, but not for #define.
#define can not define externally, and there is no way to use it for availability to the linker. Where as the constant can be global .
|
C Interview Questions and Answers for FreshersC interview questions and answers for freshers - Explain the keyword continue, How are decisions made using a switch keyword?, What is the K & R method to declare formal arguments in a function., Give one method for declaration of formal parameters