cmp

cmp <numerical variable>,<character string>,<character string>

Compares two character strings. Returns 0 if equal, a negative value if the right side is larger, and a positive value if the left side is larger.