#!/usr/bin/ruby def test puts "You are in the method" yield 1 puts "You are again back to the method" yield 2 end test {|a| puts "You are in the block #{a}"}