From: Michael Gorsuch Date: 2006-05-15T10:39:31+09:00 Subject: Re: begining programmer questions ------=_Part_29463_16472780.1147657168868 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline See, Corey. You're getting it. It just takes time, and soon enough you'll be answering our questions. On 5/14/06, corey konrad <0011@hush.com> wrote: > > oh ok i remember reading that in the book about pointers the =3D method o= r > operator whatever it is, makes something point to something else. So the > only way to truly change the variable is to change what it points too. > So i should remmeber that any time i use the =3D method i am causing > something to point to something else otherwise i might run into trouble, > that kind of makes sense. The pointer graphic -----------> helps, lol. > > > > > Daniel Baird wrote: > > On 5/15/06, corey konrad <0011@hush.com> wrote: > >> > >> yeah a friend of mine said that PHP would be a good language to learn > as > >> a beginner. > > > > > > > > Aargh! I mean, erm, no, I definitely think you're on the right track > > with > > Ruby. I know it doesn't feel like it, but you seems quite close to > > "getting" it. You're just missing the idea that variable names kinda > > "point" at objects. > > > > The object pointed at might be an array, or a string, or whatever.. wit= h > > a > > whiteboard it's quite easy to illustrate the idea, but let's try this: > > > > when you say: > > info =3D "hello there" > > > > ..that makes a pointer from the variable "info" to the string "hello > > there". Here's a picture: > > > > info ----------> String "hello there" > > > > When you say: > > > > info =3D [] > > > > ..that makes a pointer from the variable "info" to a new, empty array. > > Doesn't matter what info used to "point" to.. it's now pointing at an > > array. Like this: > > > > info ----------> Array [] > > > > > > Hope that helps a bit! > > > > ;D > > > -- > Posted via http://www.ruby-forum.com/. > > ------=_Part_29463_16472780.1147657168868--