answersLogoWhite

0

Why you use the reference variable?

Updated: 8/20/2019
User Avatar

Wiki User

12y ago

Best Answer

The reference variable controls an object. Without the

reference variable, you would have no way of accessing the object.

User Avatar

Wiki User

12y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Why you use the reference variable?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

What is reference variable and explain its uses?

Reference variable is an alias name for a previously defined variable. Its use is that the same data object can be referred by 2 names and then can be used interchangeably.


When would you use a pointer and a reference variable?

pointer: to access data by address reference: there is no reference in C language


What phrase do you use to describe a cursor variable?

static reference type


Difference between reference variable and instance variable?

An object is the actual storage space in memory in which some collection of data resides.A reference variable is a variable which refers to the memory location of an object.Look at the pseudocode below:Object obj = new Object();Here obj is the reference variable, and the data to which it refers is the object.


How to call a cell address in excel where the row number is a variable?

If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.If the row is variable but the column is fixed then it is a mixed reference. $A2 is a mixed reference. The row and column can be variable, in which case it is a relative reference. See the related question below.


What is a reference variable in c plus plus?

A reference variable in C++ is a formal parameter of a function call that automatically dereferences itself, as if it were a pointer, into a reference to the original value in the calling routine. You declare the reference type in the function declaration and prototype, but the compiler automatically adds the reference (&) operator on call, and the dereference (*) operator on use.


What type of reference is C19?

A reference variable is used to refer to or give access to an object. A reference variable is declared to be of a particular type and that type can not be altered.


What is the difference between value type parameters and reference type parameters?

When a variable is passed by value, the function receives a copy of the variable. When a variable is passed by reference, the function receives a reference, or pointer, to the original data.


Explain reference variable and how it is different from pointer variable?

In JAVA, all variables are reference variables, and there are no pointer variables. Even though the platform may implement them as pointers, they are not available as such. In C, no variables are reference variables. They are a C++ enhancement. In C++ a reference variable is syntactically the same as a pointer variable, except that the use of the indirection operator (*) is implicit. You do declare reference variables slightly differently than pointer variables but, once you do so, they can be treated as non-pointer variables. Reference variables also cannot be redefined once they have been initialized to point to some object. They are const. Structurally, there is no difference between a pointer variable and a reference variable. They are both still pointers. The compiler just makes it easier to treat reference variables and non-pointer variables the same way.


What is reference data types in java?

A reference variable is used to refer to (or access) an object. A reference variable is declared to be of a specific type and that type can never be changed. Ex: ArrayList lst = new ArrayList(); The above line creates a reference variable lst which refers to an ArrayList object


What is forward reference?

Forward reference is a terminology of coding standards. It is in which a variable is used before declaring it.


What is a variable used for in Python?

A variable is used to store information. As an example say you are asking someone for their favorite food, and want to store the answer in a variable called favoriteFood: favoriteFood = input("What is your favorite food?") Now if you print the value of favoriteFood (using print(FavoriteFood)) you will see that it has been saved in that variable. You can store any type in a variable, such as number, a string, or even an object.