answersLogoWhite

0


Best Answer

A pointer variable contains the address to some memory location. "Dereferencing" the pointer means getting the value stored at that memory location.

User Avatar

Wiki User

10y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is a use of dereferencing operator?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Dereferencing operator in c?

When we are talking about dereferencing in C we are talking about the pointers and how to get value from them, not address.Dereferencing operator notation is "*".Here is a simple example of dereferencing:int num;int pNum*;pNum = # /* make pNum pointer point to numlocation in memory/stack */*pNum = 7; /* setting pNum value to 7. Note! numvalue becomes 7 too, because pNum points to the same memory location as num */


How can an individual structure member be accessed in terms of its corresponding pointer variable?

By dereferencing the pointer variable. This can be achieved in two ways: typedef struct s { int i; float f; }; void f (struct s* p) { int x = p->i; /* using pointer to member operator */ float y = (*p).f; /* using dereference operator */ } The two methods are functionally equivalent.


When do we use an address operator in c'?

In C we use & operator while giving address of some variable to some pointer variable. & operator is also used in scanf().


Use of scope resolution operator in C programming?

:: operator can not be used in C.


What is the purpose of the operator '' when used with a pointer variable?

When a pointer variable stores a non-zero memory address, we can use the dereference operator to access the value stored at that address. This is what we mean by dereferencing and is also known as indirection because we can access a value indirectly through a pointer variable. Note that if the stored address is zero, we must not dereference the pointer as the zero address indicates that the pointer is not currently pointing at any object in particular. The zero address is a reserved address so no object can ever be allocated to it.


What is the memory management operator in c plus plus?

There is no memory management operator in C++ -- it is an unmanaged language. You use the C++ new operator to allocate memory, and use the C++ delete operator to release previously allocated memory.


When determining whether a number is inside a range which logical operator is best to use?

And operator


What is the Boolean operator that is appropriate to use?

Boolean is a type, not an operator and can have the value of either TRUE or FALSE


When to use the dot operator and when to use the arrow operator in c plus plus?

You use the dot operator when the left side is the name of the object or a reference to an object, and you use the arrow operator when the left side is a pointer to an object. Example: struct foobar x, *p= &x; x.field = p->field; (&x)->field = (*p).field;


What does the word operator means?

work


How you abbreviate operator?

For example, instead of ++ you can use ++


Is there any difference between operator and technician?

Yes, there is a difference between operator and technician. An operator typically oversees the day-to-day operation of machinery or systems, following set procedures. A technician, on the other hand, is responsible for maintaining, repairing, and troubleshooting technical equipment or systems.