C Programming Interview Questions and Answers - 8
Question: 36
What will happen if break statement is not used in switch case in C?
Switch case statements are used to execute only specific case statements based on the switch expression.
If we do not use break statement at the end of each case, program will execute all consecutive case statements until it finds next break statement or till the end of switch case block.
Question: 37
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).
Question: 38
Can the “if” function be used in comparing strings?
No. “ if”command can only be used to compare numerical values and single character values. For comparing string values, there is another function called strcmp that deals specifically with strings.
- Top 500+ C Language Interview Questions and Answers Pdf
- C Language Interview Questions and Answers
- C Language Interview Questions and Answers for Freshers
- C Language Interview Questions and Answers for Experienced
- C Programming Interview Questions and Answers
- Embedded C Interview Questions and Answers Pdf
- Top 200+ Advanced C Language Interview Questions 2020-2021
- C Programming Question Bank with Answers Pdf
- C Programming Interview Questions and Answers for Freshers
- C Programming Interview Questions and Answers for Experienced
- C Programming Basics Questions and Answers Pdf
- 1000+ Advanced C Programming Interview Questions & Answers
- 1000+ C Interview Questions and Answers 2023 - 2024 Pdf
- 1000+ C Programming Coding Questions and Answers
- 1000+ C Basic Interview Questions for Freshers Pdf
- 1000+ C Questions and Answers Pdf
Control System Questions and Answers Pdf More
GATE Analog Electronics MCQ Questions and Answers More
Analog Electronics Questions Pdf Download with Answers More
Engineering Materials Science MCQ Questions & Answers More
Material Science MCQ Questions Pdf Download More
100+ Microsoft Access Questions and Answers Pdf More
Biodiversity Multiple Choice Questions & Answers for TNPSC, NEET More
Calendar Reasoning Questions with Answers More
1000+ C Interview Questions and Answers 2023 - 2024 Pdf More
Java Threading Interview Questions and Answers for Experienced More