string interpolation in methods rails code example
Example: string interpolation ruby
# to interpolate strings in ruby use #{}
name = "Edmond"
puts "Hello, #{name}!" # outputs "Hello, Edmond!"
# to interpolate strings in ruby use #{}
name = "Edmond"
puts "Hello, #{name}!" # outputs "Hello, Edmond!"