Ludic numbers are formed by a sieve. Start with a list of the positive integers. Skip 1 and start with 2. Then delete every second number after 2 (i.e., 4, 6, 8, 10, etc.). Then move to the next number after 2—i.e., 3—and delete every third number (9, 15, 21, etc.). The next number is 5, so delete every fifth number (19, 37, etc.). Unlike the Sieve of Eratosthenes, this remaining numbers are not all prime.
Write a function to determine whether a number is a Ludic prime. The function should return three logical variables that answer these questions: Is it a Ludic prime? Is it a Ludic number? Is it prime?

Solution Stats

8 Solutions

6 Solvers

Last Solution submitted on Jul 30, 2025

Last 200 Solutions

Problem Comments

Solution Comments

Show comments
Loading...