I have compiled a list of repeatedly asking C++ interview questions here. Some of them are very important C++ questions asked by employers like Microsoft, Adobe and IBM. This list has been updated to include few more questions.
- How do you check whether a linked list is circular?
- How do you decide which integer type to use?
- How do you differentiate between a constructor and destructor?
- How do you differentiate between aggregation and association?
- How do you find out the size of a class?
- How do you implement an itoa function?
- How do you initialize a pointer to a function?
- How do you link a C++ program to C functions?
- How do you return a structure from functions?
- How do you write a function that can reverse a linked-list?
- What are the benefits of using exceptions in C++?
- What are the differences between a struct and a class in C++?
- What are the different types of Storage classes?
- What do you mean by inline function?
- What does extern mean in a function declaration?
- What does it mean to declare a function or variable as static?
- What is a conversion constructor?
- What is a copy constructor?
- What is a namespace?
- What is a pure virtual function?
- What is a scope resolution operator?
- What is abstraction?
- What is difference between #define and const?
- What is difference between function overloading and overriding?
- What is encapsulation?
- What is function overloading?
- What is multiple inheritance?
- What is operator overloading?
- What is partial specialization or template specialization?
- What is polymorphism?
- What is the difference between “passing by value” and “passing by reference”?
- What is the difference between an object and a class?
- What is the difference between declaration and definition?
- What is the difference between delete and delete[]?
- What is the difference between inner class and abstract class?
- What is the difference between persistent & non-persistent objects?
- What is the difference between structure and union?
- What is the difference between the deep copy and shallow copy?
- What is the difference between the private public and protected members?
- What is the maximum size that an array can hold?
- What is the most efficient way to reverse a linked-list?
- What is the size of an empty class?
- What is the use of virtual destructor?
- What is virtual class and friend class?
- What’s the best way to declare and define global variables?
- Where is memory for class-object allocated?
- Where is memory for struct allocated?
- Why an array always starts with index zero in C++?
- What is the block scope variable in C++?
- What is a class template?
- Does an abstract class in C++ need to hold all pure virtual functions?
- What is the order of objects destroyed in the memory?