Anonymous user
Self numbers: Difference between revisions
m
→{{header|Standard ML}}
(→{{header|Wren}}: + standard ml) |
|||
Line 1,079:
val rec sumdgt = fn 0 => 0 | n => Int.rem (n, 10) + sumdgt (Int.quot(n ,10));
val rec isSelf = fn ([],l1,l2) => []
| (x::tt,l1,l2) =>
then ( isSelf (tt,l1,l2)) else x::isSelf (tt,l1,l2)
val rec partcount = fn (n, listIn , count , selfs) =>
Line 1,104:
1022727208
</pre>
=={{header|Wren}}==
{{trans|Go}}
|