Program to print the permutation (nPr) of the given numberPermutationIt is an ordered-arrangement/combination of a set of things or collection of objects. For example, we have a set of letters A, B, and C.....describing permutations as n distinct objects taken r at a time. Permutation of a list of n elements: Algorithm
Java ProgramOutput: Enter the Value of n and r? 5 2 nPr = 20 C programOutput: Enter the Value of n and r? 5 2 nPr = 20 C# ProgramOutput: Enter the Value of n and r? 5 2 nPr = 20 Python ProgramOutput: Enter the value of n: 5 Enter the value of r: 2 nPr = 20 Next Topic# |
We provides tutorials and interview questions of all technology like java tutorial, android, java frameworks
G-13, 2nd Floor, Sec-3, Noida, UP, 201301, India