How can I print this method from the class?
I'm new to Ruby so I'm not sure who to print this. I essentially need to enter a number into this method and print.
Similar to a JS function, I know I must use puts, but that's pretty much about it.
class Celcius
def initialize(temperature)
@temperature = temperature
end
def fahrenheit
(@temperature * 1.8 + 32).round
end
def to_s
"#{@temperature} degrees C"
end
end