Wasteful, equidigital and frugal numbers: Difference between revisions
Wasteful, equidigital and frugal numbers (view source)
Revision as of 13:52, 22 July 2022
, 1 year ago→{{header|Perl}}: oops, didn't read directions...
Thundergnat (talk | contribs) m (→{{header|Raku}}: white space tweaks) |
SqrtNegInf (talk | contribs) m (→{{header|Perl}}: oops, didn't read directions...) |
||
Line 166:
elsif ( $l < $s) { push @W, $n }
else { push @F, $n }
} until
say "In base $base:";
Line 172:
say "\n$type numbers:";
say table 10, @$values[0..49];
say "
$totals .= sprintf "%11s: %d\n", $type, scalar grep { $_ <
}
say "\nOf the positive integers up to
}</lang>
{{out}}
Line 187:
74 75 76 77 78 80 82 84 85 86
Equidigital numbers:
Line 196:
105 106 107 109 111 112 113 115 118 119
Frugal numbers:
Line 205:
4913 5041 5103 5329 6241 6250 6561 6859 6889 7203
Of the positive integers up to
Wasteful:
Equidigital:
Frugal:
In base 11:
Line 221:
72 74 75 76 77 78 80 82 84 85
Equidigital numbers:
Line 230:
109 113 121 122 123 127 129 131 133 134
Frugal numbers:
Line 239:
5120 5329 6241 6250 6561 6859 6889 7168 7203 7921
Of the positive integers up to
Wasteful:
Equidigital:
Frugal:
=={{header|Phix}}==
|