A solution to the N Queens Problem in Ruby