Use a permutation when order matters and repetition is not allowed:
Return the number of ways to fill r distinct ordered roles from n people.
solve(12, 3) -> 1320 # president, VP, secretary from 12 students
Sign in to write and run your own code.
solve(...)