|
INTERVIEW QUESTIONS
PROGRAMMING LANGUAGES
C
DETAILS
Question: What is Preprocessor ?
Answer: The preprocessor is used to modify your program according to the preprocessor directives in your source code.
Preprocessor directives (such as #define) give the preprocessor specific instructions on how to modify your source code. The preprocessor reads in all of your include files and the source code you are compiling and creates a preprocessed version of your source code.
This preprocessed version has all of its macros and constant symbols replaced by their corresponding code and value assignments. If your source code contains any conditional preprocessor directives (such as #if), the preprocessor evaluates the condition and modifies your source code accordingly.
The preprocessor contains many features that are powerful to use, such as creating macros, performing conditional compilation, inserting predefined environment variables into your code, and turning compiler features on and off.
For the professional programmer, in-depth knowledge of the features of the preprocessor can be one of the keys to creating fast, efficient programs.
|
|
|
Category |
C Interview Questions & Answers -
Exam Mode /
Learning Mode
|
Rating |
(0.2) By 8339 users |
Added on |
9/18/2014 |
Views |
71805 |
Rate it! |
|
|
Question:
What is Preprocessor ?
Answer:
The preprocessor is used to modify your program according to the preprocessor directives in your source code.
Preprocessor directives (such as #define) give the preprocessor specific instructions on how to modify your source code. The preprocessor reads in all of your include files and the source code you are compiling and creates a preprocessed version of your source code.
This preprocessed version has all of its macros and constant symbols replaced by their corresponding code and value assignments. If your source code contains any conditional preprocessor directives (such as #if), the preprocessor evaluates the condition and modifies your source code accordingly.
The preprocessor contains many features that are powerful to use, such as creating macros, performing conditional compilation, inserting predefined environment variables into your code, and turning compiler features on and off.
For the professional programmer, in-depth knowledge of the features of the preprocessor can be one of the keys to creating fast, efficient programs. Source: CoolInterview.com
If you have the better answer, then send it to us. We will display your answer after the approval.
Rules to Post Answers in CoolInterview.com:-
- There should not be any Spelling Mistakes.
- There should not be any Gramatical Errors.
- Answers must not contain any bad words.
- Answers should not be the repeat of same answer, already approved.
- Answer should be complete in itself.
|
|
Related Questions |
View Answer |
|
Can a file other than a .h file be included with #include ?
|
View Answer
|
|
Can a file other than a .h file be included with #include ?
|
View Answer
|
|
How do you print an address ?
|
View Answer
|
|
What is the difference between a string copy (strcpy) and a memory copy (memcpy)? When should each be used?
|
View Answer
|
|
When should a type cast be used ?
|
View Answer
|
|
What is a null pointer assignment error? What are bus errors, memory faults, and core dumps?
|
View Answer
|
|
How can do search for data in a linked list ?
|
View Answer
|
|
When does the compiler not implicitly generate the address of the first element of an array ?
|
View Answer
|
|
What is page thrashing ?
|
View Answer
|
|
When should the register modifier be used? Does it really help ?
|
View Answer
|
|
When should the volatile modifier be used ?
|
View Answer
|
|
What is the result of using Option Explicit ?
|
View Answer
|
|
Difference between const char* p and char const* p
|
View Answer
|
|
Can you tell me how to check whether a linked list is circular ?
|
View Answer
|
|
How to reduce a final size of executable ?
|
View Answer
|
|
How to reduce a final size of executable ?
|
View Answer
|
|
What is the output of printf("%d") ?
|
View Answer
|
|
What is hashing ?
|
View Answer
|
|
#include<conio.h> main() { int x,y=2,z,a; if(x=y%2) z=2; a=2; printf("%d %d ",z,x); }
|
View Answer
|
|
main() { int i=5; printf("%d%d%d%d%d%d",i++,i--,++i,--i,i); }
|
} - C Interview Questions & Answers">
View Answer
|
Please Note: We keep on updating better answers to this site. In case you are looking for Jobs, Pls Click Here Vyoms.com - Best Freshers & Experienced Jobs Website.
View All C Interview Questions & Answers - Exam Mode /
Learning Mode
|