Giuga numbers: Difference between revisions
Content added Content deleted
m (Added language identifier.) |
|||
Line 611: | Line 611: | ||
=={{header|Java}}== |
=={{header|Java}}== |
||
Algorithm uses the mathematical facts that a Giuga number must be square-free and cannot be a semi-prime. |
Algorithm uses the mathematical facts that a Giuga number must be square-free and cannot be a semi-prime. |
||
Line 617: | Line 616: | ||
up to approximately 147,000 in around 20 milliseconds. |
up to approximately 147,000 in around 20 milliseconds. |
||
<syntaxhighlight> |
<syntaxhighlight lang="java"> |
||
import java.util.ArrayList; |
import java.util.ArrayList; |
||
import java.util.Collections; |
import java.util.Collections; |