substring

Returns the substring of the input string between the specified character indexes.

The substring begins at the character specified by the 0-based start index. If an end index is specified, the substring ends at the character immediately before this end index. Thus, the length of the substring is endIndex-startIndex. If the end index is omitted, the substring goes to the end of the input string.

Parameter 1 - any string.

Parameter 2 - the 0-based start index specifying where the substring should start.

Parameter 3 (Optional) - the 0-based end index specifying where the substring should end.

Returns: a substring of the input string.