![Image](https://mybergland.com/fwforum/patternlock.jpg)
function Main()
? NCombinations( 9, [from 3 to 9] )
// and I think the above is not correct as several solutions may be impossible
return nil
function NFactorial( n )
local nResult := 1
local x
for x = n to 1 step -1
nResult := nResult * x
Next x
return nResult
function NCombinations( n, m )
return nFactorial( n ) / ( nFactorial( m ) * nFactorial ( n - m ) )
Users browsing this forum: No registered users and 0 guests