Smallest numbers: Difference between revisions
Content deleted Content added
m →{{header|Phix}}: added a couple more tags |
m →{{header|ALGOL 68}}: typo |
||
Line 7: | Line 7: | ||
=={{header|ALGOL 68}}== |
=={{header|ALGOL 68}}== |
||
{{works with|ALGOL 68G|Any - tested with release 2.8.3.win32}} |
{{works with|ALGOL 68G|Any - tested with release 2.8.3.win32}} |
||
Uses ALGOL 68G's |
Uses ALGOL 68G's LONG LONG INT which provides large integers (the default precision is sufficient for the task). Also uses the ALGOL 68G string in string procedure. |
||
<lang algol68>BEGIN # find the smallest k such that the decimal representation of k^k contains n for 0 <= n <= 50 # |
<lang algol68>BEGIN # find the smallest k such that the decimal representation of k^k contains n for 0 <= n <= 50 # |
||
# start with powers up to 20^20, if this proves insufficient, the kk array will be extended # |
# start with powers up to 20^20, if this proves insufficient, the kk array will be extended # |