I'm planning to buy a book that has a good explanation of pointers. The C Primer Plus looks lika a possibility. Does anyone have any other recommendations?
I'm planning to buy a book that has a good explanation of pointers. The C Primer Plus looks lika a possibility. Does anyone have any other recommendations?
Pointers on C by Kenneth Reek.
This book is on my highly highly recommended list, read it, learn it, live it
-Prelude
My best code is written with the delete key.
>Pointers on C
[good, if inadvertent, pun]
hmm C / C++ : the Complete Reference [by Herbert Schildt...] and also, if you've coincidentally taken calculus... derivatives/integrals has a likeness to referencing/dereferencing which has a likeness to recursion/unwinding and nesting and etc...
hasafraggin shizigishin oppashigger...
Pointers ain't that hard. Just try using a graphics library and you'll redefine "hard".
example of pointers
output :Code:int main(int argc,char *argv[]) { int a = 4; int &b = a; printf("a = %d, b = %d",a,b); a++; printf("\na = %d, b = %d",a,b); b++; printf("\na = %d, b = %d\n",a,b); return 0; }
a = 4, b = 4
a = 5, b = 5
a = 6, b = 6
that's pretty much all there is too it....but then you have pointers to strings...which are pretty simple
Last edited by Brian; 02-12-2002 at 02:14 AM.
The C Programming Language from Kernighan&Ritchie has also a very good chapter about pointers.
Edit by Govtcheez: Now, now Brian, be nice. vVv, in case you were wondering, Brian was expressing his extreme displeasure at your statement.
This is a pretty good explanation
http://pw2.netcom.com/~tjensen/ptr/cpoint.htm