ScanSkill

endsWith

The endsWith() method checks the end of the string and matches it with the given value.

Syntax

string.endsWith(searchString)

Example

The `endsWith()` checks at the end of the string, if the given string matches with the string it is searching for, if it matches then it returns true, else returns false.

The endsWith() checks at the end of the string, if the given string matches with the string it is searching for, if it matches then it returns true, else returns false.