0
& operator
Hey friends I know if we have a code like this: int *a=&b; The value of a will be the address of b and & operator returns the address of a variable but what will be the operator performance in this code: int b; int &a=b;
2 Answers
+ 16
GHOST mHBr
This concept is introduced in C++, here a is called reference variable .
A reference variable provides an alternative name for previously defined variable
In your code -
int b;
int &a = b;
a is a reference variable which contain reference of b.
{In short, a is just another name of b}
+ 1
Thank you everyone
I understood completlyđđ