-
-
Notifications
You must be signed in to change notification settings - Fork 0
Placements
admin edited this page Jun 10, 2021
·
3 revisions
If you are already familiar with combinations, then you will easily notice that in order to find placements, you need to take all possible combinations, and then change the order in each one in all possible ways (that is, in fact, make more permutations). Therefore, the number of placements is also expressed in terms of the number of permutations and combinations
import "github.com/digital-technology-agency/math/pkg/combinatorics"
func Example() {
n := 10
k := 10
value := combinatorics.PlacementInt(n,k)
fmt.Printf("Result: %d", value)
/*
Result: 3628800
*/
}