Random attempts at solving puzzles with Ruby