EmbeddedInterviewLab
Topics
Questions
Coding
Forum
About
Toggle menu
Search topics...
⌘
K
Sign In
Back
|
Home
Home
Question Bank
C/C++ Programming & Low-Level Foundations
C / C++ Concepts
C / C++ Concepts Interview Questions
20 questions in
C/C++ Programming & Low-Level Foundations
Top
Trending
Newest
0
What does the keyword volatile mean? Give three examples of its use.
C / C++ Concepts
Keywords: volatile, const, static
foundational
0
Can a variable be both const and volatile? Give a real example.
C / C++ Concepts
Keywords: volatile, const, static
foundational
0
Does volatile make a variable access atomic?
C / C++ Concepts
Keywords: volatile, const, static
foundational
#4
0
What are the three uses of the keyword static in C?
C / C++ Concepts
Keywords: volatile, const, static
foundational
#5
0
Explain the different positions of const with pointers.
C / C++ Concepts
Keywords: volatile, const, static
foundational
#6
0
What are the memory sections in a C program, and what goes where?
C / C++ Concepts
Memory Layout
foundational
#7
0
What is the difference between .data and .bss, and why does it matter?
C / C++ Concepts
Memory Layout
foundational
#8
0
What are the problems with dynamic memory allocation in embedded systems?
C / C++ Concepts
Memory Layout
foundational
#9
0
What happens when you pass an array to a function?
C / C++ Concepts
Pointers and Arrays
foundational
#10
0
What is a dangling pointer and how do you prevent it?
C / C++ Concepts
Pointers and Arrays
foundational
#11
0
Given this struct, what is sizeof(s) and why?
C / C++ Concepts
Structs, Unions, and Alignment
foundational
#12
0
Is using a union for type punning defined behavior in C?
C / C++ Concepts
Structs, Unions, and Alignment
foundational
#13
0
Why are bitfields problematic for hardware register access?
C / C++ Concepts
Structs, Unions, and Alignment
foundational
#14
0
What is the double-evaluation trap in macros?
C / C++ Concepts
Preprocessor and Inline
foundational
#15
0
When would you use a macro instead of an inline function?
C / C++ Concepts
Preprocessor and Inline
foundational
#16
0
How do you set, clear, and toggle a specific bit in a register?
C / C++ Concepts
Bit Manipulation
foundational
#17
0
Critique this ISR. What is wrong with it?
C / C++ Concepts
Interrupts
foundational
#18
0
What does the comparison `(int)-1 > (unsigned)0` evaluate to?
C / C++ Concepts
Type Promotion
foundational
#19
0
What is a callback and how is it used in embedded systems?
C / C++ Concepts
Function Pointers and Callbacks
foundational
#20
0
What happens on an unaligned memory access, and how do you avoid it?
C / C++ Concepts
Alignment and Endianness
foundational