calcKoverI function

dynamic calcKoverI(
  1. dynamic k,
  2. dynamic i
)

Implementation

calcKoverI( k, i ) {

	var nom = 1;

	for ( var j = 2; j <= k; ++ j ) {

		nom *= j;

	}

	var denom = 1;

	for ( var j = 2; j <= i; ++ j ) {

		denom *= j;

	}

	for ( var j = 2; j <= k - i; ++ j ) {

		denom *= j;

	}

	return nom / denom;

}