This document lists 50 common questions about C++. Some of the key topics covered include: data types and memory allocation; classes vs structs; access specifiers like public, private, and protected; constructors and destructors; inheritance and polymorphism; function overloading and overriding; templates and generics; pointers and references; and linked lists. Understanding these fundamental C++ concepts is important for any developer working with the language.
This document lists 50 common questions about C++. Some of the key topics covered include: data types and memory allocation; classes vs structs; access specifiers like public, private, and protected; constructors and destructors; inheritance and polymorphism; function overloading and overriding; templates and generics; pointers and references; and linked lists. Understanding these fundamental C++ concepts is important for any developer working with the language.
This document lists 50 common questions about C++. Some of the key topics covered include: data types and memory allocation; classes vs structs; access specifiers like public, private, and protected; constructors and destructors; inheritance and polymorphism; function overloading and overriding; templates and generics; pointers and references; and linked lists. Understanding these fundamental C++ concepts is important for any developer working with the language.
This document lists 50 common questions about C++. Some of the key topics covered include: data types and memory allocation; classes vs structs; access specifiers like public, private, and protected; constructors and destructors; inheritance and polymorphism; function overloading and overriding; templates and generics; pointers and references; and linked lists. Understanding these fundamental C++ concepts is important for any developer working with the language.
Download as DOCX, PDF, TXT or read online from Scribd
Download as docx, pdf, or txt
You are on page 1of 2
Top 50 questions in c++
1. How do you check whether a linked list in circular?
2. How do you decide which integer type to use? 3. How do you differentiate between constructor and destructor 4. How do you differentiate between aggregation and association 5. How do you find out the size of a class 6. How do you implement an iota function 7. How do you initialize a pointer to a function 8. How do you link a c++ program to c functions 9. How do you return a structure from function 10. How do you write a function that can reverse a linked-list 11. What are the benefits of using exceptions in c++ 12. What are the difference between a struct and a class in c++ 13. What are the different types of storage classes 14. What do you mean by inline function 15. What does extern mean in function declaration 16. When to use virtual keyword 17. What does it mean to declare a function or variable as static 18. What is conversion constructor 19. What is a copy constructor 20. What is a namespace 21. What is a pure virtual function 22. What is a scope resolution operator 23. What is abs traction 24. What is difference between #define and const 25. What is difference between function overloading and overriding 26. What is encapsulation 27. What is function overloading 28. What is multiple inheritance 29. What is operator overloading 30. What is partial specialization or template specialization 31. What is polymorphism 32. What is difference between passing by value and passing by reference 33. What is the difference between an object and a class 34. What is the difference between declaration and definition 35. Explain the importance of virtual keyword 36. What is the difference between delete and delete[] 37. What is the difference between inner class and abstract class 38. What is the difference between persistent & non-persistent object 39. What is the difference between structure and union 40. What is the difference between the deep copy and shallow copy 41. What is the difference between the private public and protected members 42. What is the maximum size that an array can hold 43. What is the most efficient way to reverse a linked-list 44. What is the size of an empty class 45. What is the use of virtual destructor 46. What is virtual class and friend class 47. What is the best way to declare and define global variables 48. Where is memory for class-object allocated 49. Where is memory for struct allocated 50. Why an array always starts with index zero in c++