Language Guide
CHAPTER 6
Expressions
174 Operations
the left. In both cases, the items in the two lists must be in the same order. Both
Starts With and Ends With work if the operand to the right of the operator is a
single value. For example,
{ "this", "is", 2, "cool" } ends with "cool"
and
{ "this", "is", 2, "cool" } starts with "this"
and
{ "this", "is", 2, "cool" } starts with { "this", "is" }
are all true.
STRING
A string starts with another string if the characters in the string to the right of
the operator are the same as the characters at the beginning of the string to the
left. For example,
"operand" starts with "opera"
is true.
A string ends with another string if the characters in the string to the right of
the operator are the same as the characters at the end of the string to the left.
For example,
"operand" ends with "and"
is true.
AppleScript compares strings character by character according to the rules for
the Equal operator.