From: Daniel Martin Date: 2006-08-16T11:21:14+09:00 Subject: Re: [QUIZ] Newbie doubts about the quiz "Marcelo Alvim" writes: > 4) You guys could teach me a super-cool Ruby-esque way to do that that > I can't even think about right now. Note that what I did to solve this was at each step to copy the cells in the neighborhood of the current cell to a 13 by 13 array so that the current cell is the middle. This then frees me from thinking about wraparound or bounds checking while computing which move to make next. Of course, this is only possible if you have a fast way to copy a rectangular chunk of one two-dimensional array to another. Since I was using NArray, I had that. http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/208295