Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require 'mathn'
- puts "random name"
- puts "random name"
- puts " "
- puts "The program calculates the hypotenuse."
- puts "Input a:"
- a = gets
- puts "Input b:"
- b = gets
- c = Math.sqrt(a*a+b*b)
- puts "hypotenuse c: " + c
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement