Numbers with prime digits whose sum is 13: Difference between revisions
Content added Content deleted
(→{{header|Phix}}: added Pascal only counting) |
m (→{{header|Pascal}}: comment modified) |
||
Line 764: | Line 764: | ||
function CalcPermCount:NativeUint; |
function CalcPermCount:NativeUint; |
||
// |
//TempDgtCnt[0] = 3 and TempDgtCnt[1..3]= 2 -> dgtcnt = 3+3*2= 9 |
||
// |
//permcount = dgtcnt! /(TempDgtCnt[0]!*TempDgtCnt[1]!*TempDgtCnt[2]!*TempDgtCnt[3]!); |
||
//nom = 1,2,3, 4,5,6,7,8,9 |
//nom = 1,2,3, 4,5,6,7,8,9 |
||
//denom = 1,2,3, 1,2,1,2,1,2 |
//denom = 1,2,3, 1,2,1,2,1,2 |
||
Line 888: | Line 889: | ||
real 0m0,003s |
real 0m0,003s |
||
</pre> |
</pre> |
||
=={{header|Phix}}== |
=={{header|Phix}}== |
||
<lang Phix>function unlucky(sequence set, integer needed, string v="", sequence res={}) |
<lang Phix>function unlucky(sequence set, integer needed, string v="", sequence res={}) |