trim

Syntax

trim(X)

Arguments

X is a string scalar/vector.

Details

Trim all white spaces around the string.

Examples

$ x=["  t1", " t2 "];
$ trim(x);
["t1","t2"]

Related function: strip