Primality Test - iwoeix/prime GitHub Wiki

prime currently supports primality tests up to 64-bit.

You can test whether a number x is prime by including test.hpp, then calling test(x).

Example Usage:

#include <test.hpp>

using namespace prime;

int main()
{
    uint64_t x;
    std::cin >> x, std::cout << test(x) << '\n';

    return 0;
}

For details on the algorithm, see https://ceur-ws.org/Vol-1326/020-Forisek.pdf .

⚠️ **GitHub.com Fallback** ⚠️