Programming and Data Types    

Comparing for Equality Using Operators

You can use MATLAB relational operators on character arrays, as long as the arrays you are comparing have equal dimensions, or one is a scalar. For example, you can use the equality operator (==) to determine which characters in two strings match.

All of the relational operators (>, >=, <, <=, ==, !=) compare the values of corresponding characters.


  Comparing Strings For Equality Categorizing Characters Within a String