Ruby Method of the Day - String.+
Signature
string + other_string #=> new_stringstring.+ returns a new string that is composed of string concatenated with other_string.
Examples
1 2 3 4 5 6 7 |
"foo" + "bar" #=> "foobar" "foo".+("bar") #=> "foobar" x = 'foo' y = 'bar' z = 'baz' x + ' ' + z + ' ' + y #=> "foo baz bar" |
