equals

Compares one list variable with another, and returns true if both list variables contain the same elements in the same order.

Syntax:

$[ScriptVariable]::equals(List c)

Parameters:

c (List): the collection of elements to compare with the list variable.

Example:

The following example illustrates the syntax for the equals list method (using the $recipients list variable created in the add example):

$buildingFourteen = "Building 14"

$buildingFourteen::add("Winston Smythe")

$confirm = $recipients::equals($buildingFourteen)

print($confirm)

Output:

false