def k_comb(n, k): assert n > k, "Check values in k_comb!" return int(math.factorial(n) / (math.factorial(k) * math.factorial(n - k)))