Put two or more variables together with the + method: : puts « Language Basics « Ruby
- Ruby
- Language Basics
- puts
Put two or more variables together with the + method:
hi = "Hello, "
person = "Matz!"
puts hi + person # => Hello, Matz!
Related examples in the same category