Assignment #11, solution_11.rb ver 2