Math.Permutation("5", "3");
5P3 = 5! / (5-3)! = 60
->
60
1 2 3 4 5 6 7 8 9 10 | /// <summary> /// https://groophy-inc.github.io/permutation /// </summary> /// <param name="n"></param> /// <param name="k"></param> /// <returns></returns> public static GValue Permutation(GValue n, GValue k) { return (Division(Factorial(n), Factorial(Subtraction(n, k)))); } |
Copyright © Groophy.Inc ' Batch-Man