How to create a reference variable in C++



How to create a reference variable in C++..

Answer / 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

More C++ General Interview Questions

Define precondition and post-condition to a member function?

1 Answers  


When is a template a better solution than a base class?

1 Answers  


Explain about profiling?

1 Answers  


What is the oldest programming language?

0 Answers  


How do you remove an element from a set in c++?

0 Answers  






What do you mean by “this” pointer?

0 Answers  


What is an undefined reference/unresolved external symbol error and how do I fix it?

0 Answers  


Write a program to calculate the following i want a c++program for this condition 1+4+9+16+….+100 Like this (1^2+2^2) Hint use function pow(a,b)

4 Answers   HTC, TCS,


What are the differences between public, private, and protected access?

12 Answers   IBM, Oracle, Wipro,


What do you mean by volatile and mutable keywords used in c++?

0 Answers  


What is c++ used for in games?

0 Answers  


what are Operators and explain with an example?

0 Answers  


Categories