thank you.
> On Apr 14, 2016, at 10:54 AM, Ron Teitelbaum [via Smalltalk]
> wrote:
>
> Hi Joseph,
>
> | aPoint aDictionary |
>
> aPoint := Point x: 1 y: 2.
> aDictionary := Dictionary new.
> aDictionary at: aPoint put: 'Success!'.
> ^aDictionary at: aPoint
>
> Everything in Smalltalk is an object. You can use a number or string as
> your dictionary key but you can also use more complex objects like a Point.
>
> The object matching is implemented in #=. If the objects match then the
> value will be returned.
>
> All the best,
>
> Ron Teitelbaum
>
> > -Original Message-
> > From: [hidden email] [mailto:beginners-
> > [hidden email]] On Behalf Of Joseph Alotta
> > Sent: Wednesday, April 13, 2016 9:46 PM
> > To: [hidden email]
> > Subject: [Newbies] f(x, y) or Table
> >
> > Greetings,
> >
> > I find a lot of my data needs two indices, f(x,y) instead of one, f(x).
> >
> > f(x) would be implemented easily with a Dictionary,
> >
> > but how do you implement f(x,y)?
> >
> >
> > I guess this is another way of asking is there a Table object or a Tuple
> object,
>
> >
> > of even a graphics object Screen that has x,y coordinates with a value?
> >
> >
> > Sincerely,
> >
> > Joe.
> >
> >
> >
> >
> >
> >
> > ___
> > Beginners mailing list
> > [hidden email]
> > http://lists.squeakfoundation.org/mailman/listinfo/beginners
>
> ___
> Beginners mailing list
> [hidden email]
> http://lists.squeakfoundation.org/mailman/listinfo/beginners
>
>
> If you reply to this email, your message will be added to the discussion
> below:
> http://forum.world.st/f-x-y-or-Table-tp4889801p4890068.html
> To start a new topic under Squeak - Beginners, email
> ml-node+s1294792n107673...@n4.nabble.com
> To unsubscribe from Squeak - Beginners, click here.
> NAML
--
View this message in context:
http://forum.world.st/f-x-y-or-Table-tp4889801p4890103.html
Sent from the Squeak - Beginners mailing list archive at Nabble.com.___
Beginners mailing list
Beginners@lists.squeakfoundation.org
http://lists.squeakfoundation.org/mailman/listinfo/beginners