Advertisement
saasbook

block_example_2.rb

Jan 10th, 2012
323
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.17 KB | None | 0 0
  1. separator = '=>'
  2. print_movies(movies)
  3. #
  4. def print_movies(movie_list)
  5.   movie_list.each do |m|
  6.     puts "#{m.title} #{separator} #{m.rating}"  # === FAILS!! ===
  7.   end
  8. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement