I have forgotten

• https://me.yahoo.com
COST (GBP)
0.10
0.00
0

# Permut

Calculates the number of permutations for a given set of data.
Controller: CodeCogs
Contents

C++
HTML

## Permut

 doublepermut( int n int k )
Returns the <em>number of permutations</em> for a given number of objects that can be selected from number objects.

A permutation is any set or subset of objects or events where internal order is significant.

Permutations are different from combinations, for which the internal order is not significant. Use this function for lottery-style probability calculations. The equation for the number of permutations is:

### Example 1

#include <codecogs/statistics/moments/permut.h>
#include <iostream>
int main()
{
double per = Stats::Moments::permut(6, 2);
std::cout << "The number of permutations is: " << per<< std::endl;
return 0;
}
Output:
The number of permutations is: 30

### Parameters

 n is an integer that describes the number of objects k is an integer that describes the number of objects in each permutation.

### Returns

the number of permutations for a given set of data

### Authors

Anca Filibiu (August 2005)
##### Source Code

Source code is available when you agree to a GP Licence or buy a Commercial Licence.

Not a member, then Register with CodeCogs. Already a Member, then Login.