Click here for AnswerPool.com Home page


Google

    AnswerPool.com  Hop To Forum Categories  Computers  Hop To Forums  Computer Resources    pointer

Moderators: Dwight
Go
Post
Find
Notify
Tools
Reply
  
  Login/Join 
Diamond
Enthusiast

Picture of Leppi
Posted
I was wondering if someone could give me a basic explination of what is a pointer in c++ and how it is used. I tried searching online, and I got a complicated answers (not for someone who has never heard of the consept before.) thanks very much....
 
Posts: 3144 | Location: looking for planet earth | Registered: 06-03-02Reply With QuoteEdit or Delete MessageReport This Post
Gold
Enthusiast
Posted Hide Post
From Teach Yourself C++ in 24 Hours (2nd Ed.) (ISBN: 0672315165) by Jesse Liberty:
quote:
p134: A pointer is a variable that holds a memory address.


A code snippet (from p137):

int howOld = 50; // Make a variable
int * pAge = 0; // Make a pointer
pAge = &howOld; // put howOld's address in pAge


Essentially, its how c++ gives you low-level access to RAM. Tred with care.

Hope this was helpful.
 
Posts: 1003 | Location: Fox Valley, Second Life | Registered: 06-03-02Reply With QuoteEdit or Delete MessageReport This Post
 Previous Topic | Next Topic powered by eve community  
 

    AnswerPool.com  Hop To Forum Categories  Computers  Hop To Forums  Computer Resources    pointer

© 2002-2008 AnswerPool.com



Visit DiscussionPool.com!