The nPr termed as permutation. They are useful in finding possible permutation of the number in the sets of numbers. To calculate combinations, we will use the formula nPr = n! / (n – r)! , where n represents the total number of items, and r represents the number of items being chosen at a time.
Output:
Enter the value of num = 10
need an explanation for this answer? contact us directly to get an explanation for this answerEnter the value of r = 4
10 P 4 = 5040