Chalkboard - v3.0.1
    Preparing search index...

    Function permutation

    • Returns the combinatorial permutation of two numbers.

      Parameters

      • n: number

        First number (total items)

      • r: number

        Second number (chosen items)

      Returns number

      // The number of different ways to arrange the word "MATH" is 24
      const permute = Chalkboard.numb.permutation(4, 4);