added ex2.rb