ListEndsWithList

Typeoperator
DictionaryLCB
LibraryLiveCode Builder
Syntax
<Source> ends with <Suffix>
Associationscom.livecode.list
Summary

Determines whether Source ends with Suffix Prefix:An expression which evaluates to a list.

Parameters
NameTypeDescription
Source

An expression which evaluates to a list.

Example
variable tVar as List
put [1, 2, 3, 4, 5] into tVar

variable tEnds as Boolean
// put tList ends with tList[5] into tEnds -- error: tList[5] is not a list 

put tList ends with element 1 to 5 of tList into tEnds -- tEnds is true
Values
NameTypeDescription
return

Returns true if Source ends with Suffix.

Description

Source ends with Suffix if and only if the elements of Suffix occur as a final subsequence of the elements of Source.

Note: Since the empty list is a final subsequence of every list, every list ends with the empty list.

Tagslists