From: Thufir Date: 2008-02-22T17:46:37+09:00 Subject: Re: Beginner help - txt dungeon On Thu, 21 Feb 2008 06:41:54 +0900, Huw Collingbourne wrote: > The attraction of a hash is that the key would not need to be a number - > it could actually the name of a room { :east => :dungeon, :south => > :cave } and so on. > > In fact, I wrote a simple example of a game framework in Smalltalk that > uses exactly this method: > > map at: 'Station 1' put: 'Belsize Park'; > at: 'Station 2' put: 'Chalk Farm'; > at: 'Station 3' put: 'Camden Town'; > at: 'Your destination' put: 'Mornington Crescent'. Yes, that's much more readable than mapping integers around :) Ok, I'm starting to see the advantages to Hash! -Thufir