For What I need the @#$# Pointers?

This is a discussion on For What I need the @#$# Pointers? within the C++ Programming forums, part of the General Programming Boards category; i cant uderstand!!!!...

  1. #1
    Registered User
    Join Date
    Mar 2002
    Posts
    88

    For What I need the @#$# Pointers?

    i cant uderstand!!!!

  2. #2
    ....
    Join Date
    Aug 2001
    Location
    Groningen (NL)
    Posts
    2,386
    I suggest you write some @#$# lprograms and you'll experience that you can't without.

  3. #3
    Just a Member ammar's Avatar
    Join Date
    Jun 2002
    Posts
    953

    Lightbulb

    Pointer are very important especialy with classes and in windows programming.

  4. #4
    Registered User
    Join Date
    Mar 2002
    Posts
    88
    but what the point of the pinters...?

    can any one give me an EX?

  5. #5
    Registered User
    Join Date
    Apr 2002
    Posts
    1,571
    Imagine if you will, you have a class in your game that is very big. Let's say it takes up a few megs. Whenever you want to pass that class to a function to have something performed on it , if you DO NOT use pointers a copy of the class is made and then passed to the function. This is very slow and horrible for speed. Instead you could pass a pointer TO the class. A pointer is just something that points to a memory address so it is usually 4 Bytes. This way only the address is passed and you can directly modify the class.
    "...the results are undefined, and we all know what "undefined" means: it means it works during development, it works during testing, and it blows up in your most important customers' faces." --Scott Meyers

  6. #6
    Registered User
    Join Date
    Feb 2002
    Posts
    3
    polymorphism is achieved through a combination of inheritance and pointers.

    the topic of pointers is very important in c/c++ programming, i used to wish that pointers have not existed back in the days of my c class i feared and hated it.

    just learn it at a comfortable pace and u'll soon be using pointers as would terminate a statement with a ;.

  7. #7
    Registered User
    Join Date
    Mar 2002
    Posts
    88
    Thax

    i know how to use them
    but i dont understand Y

    so i'll learn more

    thanx

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Using pointers to pointers
    By steve1_rm in forum C Programming
    Replies: 18
    Last Post: 05-29-2008, 05:59 AM
  2. Replies: 4
    Last Post: 12-10-2006, 06:08 PM
  3. Request for comments
    By Prelude in forum A Brief History of Cprogramming.com
    Replies: 15
    Last Post: 01-02-2004, 09:33 AM
  4. Staticly Bound Member Function Pointers
    By Polymorphic OOP in forum C++ Programming
    Replies: 29
    Last Post: 11-28-2002, 12:18 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21