Doing a calculation : Variables « Language Basics « Ruby
- Ruby
- Language Basics
- Variables
Doing a calculation
temperature = 36
puts "The temperature is " + String(temperature) + "."
temperature = temperature + 5
puts "Now the temperature is " + String(temperature) + "."
Related examples in the same category