How to create a reference variable in C++

Answer Posted / hrpynux@gmail.com

When a variable is declared as a reference, it becomes an alternative name for an existing variable. A variable can be declared as a reference by putting '&' in the declaration.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a hash function c++?

556


What is the copy-and-swap idiom?

612


Define a conversion constructor?

626


What is c++ programming language?

582


What is class syntax c++?

596






What is the default width for ouputting a long integer using the insertion operator?

694


What are c++ storage classes?

622


Which function cannot be overloaded c++?

581


What is a manipulator in c++?

717


Explain the use of vtable.

622


What is the need of a destructor?

641


How is static data member similar to a global variable?

587


Differentiate between a template class and class template in c++?

636


Why c++ is called oop?

603


Explain the auto storage classes in c++.

606