Assignment 12, solution_12.rb, Loop excercise