C++
Programming and Technical
What do you mean by reference variable in c++?
Read Solution (Total 1)
-
- A variable provides an alias(alternative name) for previously defined variable.
Declaring a variable as a reference rather than a normal variable simply appending an ampersand to the type name, such as this "reference to an int"
int& foo = ....;
for example
int x;
int& foo = x;
// foo is now a reference to x so this sets x to 56
foo = 56;
std::cout - 10 years agoHelpfull: Yes(1) No(0)
C++ Other Question