.compareTo(String string): This method compares two strings lexicographically and returns an integer value based on the comparison result.
.startsWith(String prefix): This method checks if a string starts with a specified prefix.
.endsWith(String suffix): This method checks if a string ends with a specified suffix.