On 05.05.2011 21:06, Stefan Salewski wrote:
> But now we really need many tanks, each with very many fishes.
> Currently it seems to be a bit strange giving each of thousands
> fishes a reference to its tank.
You can control the fishes within the tank. Every fish is saved in an 
array in tank. The tank queries every fish for it's mood ?

http://pastie.org/1870880

> Another solution may be to give the .tell_state() function a tank
> parameter each time when we call it. (A tank-temperature parameter
> is not a good idea, because we may need more, light, food...)
Why not? Pass them via a hash?
IMO there's no need for a fish to know its tank.


--
Johannes