Constructor Overloading
In our previous article of “Function Overloading”, we had discussed how a function can be overloaded. In this article, we will focus on Constructor Overloading. Similar to other normal function, we canRead More…
In our previous article of “Function Overloading”, we had discussed how a function can be overloaded. In this article, we will focus on Constructor Overloading. Similar to other normal function, we canRead More…
Overloading refers to the process of using the same thing for different purposes. It is also referred to as function polymorphism. It works on the concept “Same name, multiple tasks”. In programmingRead More…
Problem in Using Normal Function The main advantage of function is to save codding efforts, memory space and reusability. But whenever we call a function, it consume a lot of time sayRead More…
Destructor is a special member function of a class, which is used to destroy the object. Like a constructor, it has same name as of class name, but it is preceded byRead More…
A class is defined with the goal of creating user defined data type, which is similar to build-in-data-type. Built-in data type variables can be initialized at the time of declaration but weRead More…
Static Data Member (Class variable): Static Data member has the following properties: It is initialized by zero when first object of class is created. Only one copy of static data member isRead More…
Similar to passing primary data-type variables, we can also pass object as argument to the function. Objects can be passed by two methods: Call by value: In this method a copy ofRead More…
As we know that in C programming language it is compulsory to pass all arguments during function call, which are used in function definition, but C++ allows us to call a functionRead More…
Function in C++ program is similar to function in C program. Function provides the top-down structured programming approach. It also provides re-usability that means we can use the same function multiple times.Read More…
Class: “A Class is a user defined data type that combines both data and method into a single unit known as class”. “In other words, a class is a container which includesRead More…