[#5] example.rb implelented accordingly to requirements in issue #5