Skip to content

Instantly share code, notes, and snippets.

@ykws
Created November 20, 2019 17:21
Show Gist options
  • Save ykws/36dcaa7cf3950766d3e5437c2c969fc3 to your computer and use it in GitHub Desktop.
Save ykws/36dcaa7cf3950766d3e5437c2c969fc3 to your computer and use it in GitHub Desktop.
Access to a file without Ruby Blocks
File.open(ARGV[0], 'r') do |file|
puts file.read
end
@ykws
Copy link
Author

ykws commented Nov 20, 2019

do || - end is Ruby Blocks, too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment