Class: JsonPrinter
- Inherits:
-
Object
- Object
- JsonPrinter
- Defined in:
- lib/json_printer.rb
Class Method Summary collapse
-
.printer(celcius, fahrenheit, kelvin) ⇒ Object
Prints the three formats of temperature in a JSON string.
Class Method Details
.printer(celcius, fahrenheit, kelvin) ⇒ Object
Prints the three formats of temperature in a JSON string
4 5 6 |
# File 'lib/json_printer.rb', line 4 def self.printer(celcius, fahrenheit, kelvin) puts "{celcius: #{celcius}, fahrenheit: #{fahrenheit}, kelvin: #{kelvin}}" end |