Ton Hospel wrote: > > Another one that was done as a (very quick, only half a day) ircnet golf > for you to try your teeth on. > Won by mtve with a score of 85, but in the postmortem we are at 77. > How well can the mailinglist do this as an open golf (post your attempts > here) > Only for people who haven't played it and haven't looked at the web page. > > Consider a 2x2 square where each position can be filled (represented by a O > (that's not a zero)), or empty (represented by a .). You can then > look how many elements are filled on each row and column, for example: >
i got 131, so not really threatening the leaderboard. sub p{$a[pop]+$a[pop]}sub r{($_/=2)&1}map{@a=(r,r,2,r,r,2);pop,print+('.',O,$/)[@a]if p(0,1).p(3,4).$".p(0,3).p(1,4)eq"@ARGV"}0..31 two subroutines! my only excuse is that i am doped up on codeine after breaking both arms (so one was only chipped, sue me), and didn't spend too long on it. jasper hmmm, just looked at leaderboard. not threatening anyone. drat. -- Neil, is it really necessary to nail the plates to the table? What happens when we want to play Monopoly? Go directly to plate? Do not pass plate nailed to the table by a stupid hippie? - Vyvyan