Pandigital prime: Difference between revisions
m
→{{header|Phix}}: removed non-0 version
(added optional use of 0) |
m (→{{header|Phix}}: removed non-0 version) |
||
Line 253:
=={{header|Phix}}==
As you can see it does not have to generate and test many candidates for primality before it finds the (or no) answer.<br>▼
You could of course easily change the main loop to go from 9 down to 1 and quit once any answer is found.▼
<!--<lang Phix>(phixonline)-->
<span style="color: #008080;">with</span> <span style="color: #008080;">javascript_semantics</span>
Line 336 ⟶ 283:
<!--</lang>-->
{{out}}
▲As you can see it does not have to generate and test many candidates for primality before it finds the (or no) answer.<br>
▲You could of course easily change the main loop to go from 9 down to 1 and quit once any answer is found.
<pre>
1
|