Template In CPP
Templates are the generic data type. It converts into any type of data type automatically. We do not have to write float, int, char, string etc. Note: For both the…
Templates are the generic data type. It converts into any type of data type automatically. We do not have to write float, int, char, string etc. Note: For both the…
When a class contains more than one function with the same name but with different parameters is called the method overloading. By this, a single function can perform multiple tasks that…
A Constructor is a special member function of a class. It initializes the memory object data by default when we create an object of the class. Constructor name is same as…
Scope resolution operator is used to specify the scope of a member function. It is used to access a global variable. #include<iostream.h> #include<conio.h> #include<string.h> class A { int rno; char name[10];…
The key features of OOPS concept are: 1. Object 2. Class 3. Data Encapsulation 4. Data Abstraction 5. Inheritance 6. Polymorphism 1.Object - This is the basic unit of OOPS.…
This program will ask the user to input a string of maximum 40 characters and then it will count vowels in the given string. #include<iostream.h> #include<conio.h> #include<stdio.h> void main() {…
This program will accept birthyear and birth month from the user and also accept the current year and current month, according to the given input this program will calculate the…