out =
strcmp (A, B)
¶String comparison.
Tests whether each element in A is exactly equal to the corresponding element in B. Missing values are not considered equal to each other.
This does the same comparison as A == B
, but is not polymorphic.
Generally, there is no reason to use strcmp
instead of ==
or eq
on string arrays, unless you want to be compatible with
cellstr inputs as well.
Returns logical array the size of the scalar expansion of A and B.