Skip to content

Main content

List Adjacent Equality Mask Tool

Mark exact string equality with the preceding list item; the first position is always false.

Loading tool…

Description

Return false at the first item and exact equality with the preceding item at every later position.

Token lists preserve element boundaries that raw character matching can lose. Prefix-suffix overlap and separator placement depend on exact element and empty-list conventions.

Return false at the first item and exact equality with the preceding item at every later position.

When to use this tool

Use List Adjacent Equality Mask when you need a token-boundary overlap or separator-count calculation.

How to use the tool and how it works

  1. Enter items. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read equalToPrevious. Use the output convention below.

Return false at the first item and exact equality with the preceding item at every later position.1

Input fieldMeaning and unitsAccepted input
itemsItemsRequired. Array of text; maximum UTF-16 length 8192; maximum items 256.
Output fieldInterpretationReturned shape
equalToPreviousEqual To PreviousRequired. Array of boolean; maximum items 256.
json
{
  "input": {
    "items": [
      "a",
      "a",
      "b",
      "b"
    ]
  },
  "output": {
    "equalToPrevious": [
      false,
      true,
      false,
      true
    ]
  }
}

Limitations and assumptions

  • The input is not deduplicated or normalized; false at position zero means no predecessor rather than a value mismatch.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.

Alternative or Complementary methods

Choose token normalization and escaping rules before joining or merging the actual list contents.

References

  1. Calculation and input contract: list/list-adjacent-equality-mask — tool.io

Similar or alternative tools