Prelude API
    Preparing search index...

    Function delete

    • Deletes i occurrences of the element with the provided key.

      Type Parameters

      • T
      • K

      Parameters

      Returns [T | undefined, number]

      tuple of removed element (undefined when the key is missing or only some of its occurrences were removed) and remaining count (negative when more occurrences were requested than existed, 0 when the key was missing).