CPP Viva
CPP Viva
Variables must start with a letter or underscore, cannot use keywords, and must only contain
Controlled loops execute a block of code repeatedly. Types are: for, while, and do-while loops.
Function overloading allows multiple functions with the same name but different parameters.
Example:
6. What is recursion?
Inheritance allows one class to acquire properties of another. Types: Single, Multiple, Multilevel,
C++ is needed for its efficiency, support for object-oriented programming, and system-level features.
Access specifiers define the scope of class members. Types: public, private, and protected.
Derived data types are built from basic types. Examples: Arrays, Pointers, References.
Operators are symbols for operations. Types: Arithmetic, Relational, Logical, Bitwise, Assignment,
etc.
Strings store sequences of characters. C++ provides std::string for string manipulation.