string.plus
string: newstr = plus (str1, str2)
Append strings.
newstr = lower (str) is the equivalent of the syntax
newstr = str1 + str2 and appends str2 to
str1. Both input arguments must be string arrays of compatible
size.
Source Code: string
plus (+) concatenates two strings — a compact alternative to append. Both operands must be strings (a bare '-' is a char, so wrap it).
a = string ({'Ann'; 'Bob'})
a =
2x1 string array
"Ann"
"Bob"
b = string ({'Lee'; 'Ng'})
b =
2x1 string array
"Lee"
"Ng"
a + string (' ') + b
ans =
2x1 string array
"Ann Lee"
"Bob Ng"