• Index of the entry with the highest effective mastery level (the "best chance" default), or -1 for an empty list. Pure.

    Type Parameters

    • T

    Parameters

    • entries: T[]

      The candidate entries to compare.

    • ml: (entry: T) => number

      Extracts the effective mastery level from an entry.

    Returns number

    The index of the highest-mastery entry, or -1 if entries is empty.