What is the use of default constructor, C/C++ Programming

Assignment Help:

What is the use of default constructor?

- It's a constructor that doesn't accept any parameters.

- If there is no user-defined constructor for a class, compiler declares a default parameter less constructor known as default constructor. It's an inline public member of its class.

When compiler uses this constructor to create an object -constructor will have no constructor initializer and a null body.

 


Related Discussions:- What is the use of default constructor

Explain difference between early binding and late binding, What is the diff...

What is the difference between early binding and late binding? What are advantages of early binding? a.) Late binding refers to function calls which aren't resolved until run t

Random card generator, i need a program that generates this output: The hig...

i need a program that generates this output: The highest card wins! Suit Order is: clubs, diamonds, hearts and spades The computers card is the 5 of Spades. The player’s card is t

Write a program to sum any pair of numbers, Write a C++ program that reads ...

Write a C++ program that reads from keyboard 3 integers, with proper input prompt, and then displays the maximum sum of any pair of numbers from these three. If the 3 numbers are 5

Mini Search Engine, How do I create two functions: one to put a collection ...

How do I create two functions: one to put a collection of criteria into normal form, and one to compute the score of a document. A collection of criteria will be represented using

Program to calculate tax - c++, Program to calculate tax: float tax (f...

Program to calculate tax: float tax (float) ; int main() {                 float purchase, tax_amt, total;                 cout                 cin >> purchase

Conversion operator, What is conversion operator? Explain it with example.

What is conversion operator? Explain it with example.

Define a procedure called make-avl-tree, This question deals with AVL trees...

This question deals with AVL trees. The representation to be used is similar to the bank account object discussed in class. (a) Define a procedure called make-avl-tree which mak

Caesar cipher, This task involves char arrays and pointer based string hand...

This task involves char arrays and pointer based string handling. Which we use to make a simple encryption program, using a Caesar Cipher, Write a program that: a. Asks

Program for basically a small store, ¦It should ask customers to enter deta...

¦It should ask customers to enter details such as their names and addresses. ¦It should print a welcome message that includes the customer’s name. ¦It should provide a list of avai

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd