String Concatenation in V

Posted by yhuang
Public (Editable by Users)
V
None
Edit
s := "hello"
s2 := s + " world" // + is used to concatenate strings
println(s2)

mut s3 := "hello "
s3 += "world" // += is used to append to a string
println(s3) // "hello world"