Linux Today: Linux News On Internet Time.
Search Linux Today
Linux News Sections:  Developer -  High Performance -  Infrastructure -  IT Management -  Security -  Storage -
Linux Today Navigation
LT Home
Contribute
Contribute
Link to Us
Linux Jobs


Top White Papers

More on LinuxToday


C++ : Understanding pointers

Sep 17, 2009, 15:02 (5 Talkback[s])

[ Thanks to linuxconfig.org for this link. ]

"2. What is a Pointer?

"Pointer is a variable that stores a memory address. OK, that is simple ! But, what is a memory address then? Every variable is located under unique location within a computer's memory and this unique location has its own unique address, the memory address. Normally, variables hold values such as 5 or "hello" and these values are stored under specific location within computer memory. However, pointer is a different beast, because it holds the memory address as its value and has an ability to "point" ( hence pointer ) to certain value within a memory, by use of its associated memory address.

"3. Retrieving a Variable's Memory Address

"OK, enough talking and let's get down to the pointer business. To retrieve a variable's memory address, we need to use address-of operator &."

Complete Story

Related Stories: