C Programming INTERVIEW QUESTIONS
Languages
25. | What is memory leak? |
---|---|
|
26. | What are the Escape sequences present in C? |
---|---|
|
27. | What is the difference between auto variable and register variable in C? |
---|---|
Storage class of all variables is auto by default unless we specify a variable is register or static or extern in C program. Register variables will be accessed very faster than the normal/auto variables. Since they are stored in register memory rather than main memory. But only limited variables can be used as register since register size is very low. (16 bits, 32 bits, or 64 bits). |
28. | What is const pointer in C? |
---|---|
Const pointer is a pointer that can't exchange the address of the variable that of pointing to. Once const pointer is made to point one variable, we can't change this pointer to point to any other variable. This pointer is called const pointer. |