C++ Online Tutorials

Learn C++
C++ language is very important for placements and a lot of questions will be asked from theory concepts in Online tests of various companies and also interviews. The pages below can also be used for general C++ learning and will cover all important topics for C++.

Introduction
Here we will learn about the structure of C++ language and the syntax in order to construct a feasible code. These are important topics and you need to be thorough in these topics before you move further.
C++ vs C
Here we will learn about basic difference between C++ and C
1. Programming Paradigm:
- C is a procedural programming language, which follows a top-down approach and focuses on functions and procedures.
- C++ is a multi-paradigm language that supports both procedural and object-oriented programming (OOP), allowing concepts like classes, inheritance, and polymorphism.
2. Code Reusability:
- In C, code reusability is limited and achieved using functions.
- In C++, object-oriented features like classes and inheritance promote better code reusability and modularity.


Input/Output
Here we will learn about how input/output work in c++ and different type conversion
Operators and variables
Here we will learn about different types of operators and variables used in C++


Conditional statement
Here we will learn about how input/output work in c++ and different type conversion
Array and String
Here we will learn about what array , string are and how they work in C++ Programming.


Function
Here we will learn about what Function and how they are used in C++ Programming.
- Function
- Call by Value Vs Call by Reference
- Member functions in C++
- Static Members in C++
- const in C++
- Inline function in C++
- Friend Function and Friend Class
- virtual
- Function Overriding in C++
- Function Overloading in C++
- Difference between Function Overriding and Function Overloading in C++
- Recursion
- Return reference
- floor function in c++
- Ceil function in c++
- Function types
Structures in c++
Here we will learn about what Structures and how they are used in C++ Programming.


Pointers
Here we will learn about what Pointers and how they are used in C++ Programming.
Object and class in c++
Here we will learn about what Oject , Class and how they are used in C++ Programming.


STL in C++
Here we will learn about what STL and how they are used in C++ Programming.
Containers in STL
Here we will learn about what Container in STL and how they are used in C++ Programming.


Math in STL
Here we will learn about how math is used in STL C++ Programming.
Exception Handling
Here we will learn about Exception Handling and how they are used in C++ Programming.


Library in C++
Here we will learn about Library in C++ and how they used in C++ Programming.

Introduction to Classes and OOPs Concept
In C++, Object-Oriented Programming (OOP) is a way of writing code by creating objects that represent real-world things. These objects are made using classes.
What is a Class?
- A class is like a blueprint or template. It defines how an object will look and what it can do. It contains data (called variables) and functions (called methods) that work on that data.
What is an Object?
An object is created from a class. It is a real thing you can use in your program.
Basic OOPS Concepts in C++
- Encapsulation – Wrapping data and functions together inside a class. It hides the internal details.
- Inheritance – A class can use features of another class. Example: ElectricCar can inherit from Car.
- Polymorphism – One function behaves differently based on how it’s used. Helps with flexibility.
- Abstraction – Showing only the important details and hiding the rest.
OOPs Advanced - 1
- Class and Object
- Encapsulation
- Abstraction
- Inheritance
- Polymorphism (Basic)
- Function Overloading
- Operator Overloading
- Access Specifiers (public, private, protected)
- Constructors and Destructors
- Copy Constructor


OOPs Advanced - 2
- Runtime Polymorphism (Function Overriding)
- Virtual Functions
- Pure Virtual Functions
- Abstract Classes
- Virtual Base Class
- Constructor and Destructor in Inheritance
- Multiple Inheritance & Ambiguity Resolution
- Friend Function and Friend Class
- Static Members (Variables and Functions)
- ‘this’ Pointer
- Pointer to Objects
- Dynamic Memory Allocation in Classes
- Namespaces
- Type Casting in OOP (static_cast, dynamic_cast, etc.)
Dynamic memory


Basic Programs
Set 1
- A character is a vowel or consonant
- A character is an alphabet or not
- Ascii values of a character
- Uppercase, Lowercase or special character
- A number is positive or negative
- A number is even or odd
- Area of a circle
- LCM of two numbers
- GCD of two numbers
- HCF of two numbers
- Greatest of two numbers
- Greatest of three numbers
- Number of digits in an integer
- Sum of digits of a number
- Sum of N natural numbers
- Sum of numbers in a given range
- Reverse of a given number
- Factorial of a number
- Fibonacci series up to n
- Leap year or not
- Prime number or not
- Palindrome or not
- Armstrong number or not
- Strong number or not
- Perfect number or not
- Automorphic number or not
- Harshad number or not
- Abundant number or not
- Power of a number
- Factors of a number
- Add two fractions
Set 2
- Prime numbers in a given range
- Armstrong numbers between two intervals
- Can a number be expressed as a sum of two prime numbers?
- Replace all 0’s with 1 in a given integer
- Binary to decimal conversion
- Decimal to binary conversion
- Decimal to octal conversion
- Octal to decimal conversion
- Binary to octal conversion
- Octal to binary conversion
- Maximum number of handshakes
- Quadrants in which coordinates lie
- Convert digit/number to words
- Number of days in a given month of a given year
- Permutations in which n people can occupy r seats in a classroom
- Number of times x digit occurs in each and every number from 0 to n
- Number of integers which has exactly x divisors
- Roots of a quadratic equation
- Count possible decoding of a given digit sequence
Miscellaneous Coding Questions
- Fuel Consumption –
Click here - Cyclically rotate an array by K positions
– Click Here - Prime sum of Nth power –
Click Here - Playing with strings containing vowels –
Click Here

Login/Signup to comment