Skip to content

Instantly share code, notes, and snippets.

@maxdignan
Created March 4, 2018 18:07
Show Gist options
  • Save maxdignan/5ee4983c653763507ad6fec38afc0d5d to your computer and use it in GitHub Desktop.
Save maxdignan/5ee4983c653763507ad6fec38afc0d5d to your computer and use it in GitHub Desktop.
module SpecialLogger
def log(value)
puts "Here's your value: #{value}"
end
module_function :log
end
SpecialLogger.log((1+1) / 2) #-> puts "Here's your value: 1"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment