Skip to content

Instantly share code, notes, and snippets.

@mistyrinth
Created November 28, 2018 08:20
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
num1 = 10
num2 = 3
puts "#{num1} / #{num2} = #{num1 / num2}"
puts "#{num1}.div(#{num2}) = #{num1.div(num2)}"
puts "#{num1}.divmod(#{num2}) = #{num1.divmod(num2)}"
puts "#{num1}.fdiv(#{num2}) = #{num1.fdiv(num2)}"
puts "#{num1}.quo(#{num2}) = #{num1.quo(num2)}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment