strcmp method

int strcmp(
  1. String str1,
  2. String str2
)

Compares the string str1 to the string str2. Returns 0 if they are equal, a negative value if str1 is less than str2, and a positive value if str1 is greater than str2.

Implementation

int strcmp(String str1, String str2) => str1.compareTo(str2);