1 // This program prints the smallest probable prime >= x, x being given on the
4 // We work with real numbers and integers.
6 #include <cln/integer.h>
10 #include <cln/integer_io.h>
12 // The function nextprobprime() is part of the number theory package.
13 #include <cln/numtheory.h>
15 int main (int argc, char* argv[])
18 std::cerr << "Usage: nextprime x" << std::endl;
21 cln::cl_R x = (cln::cl_R)argv[1];
22 cln::cl_I p = cln::nextprobprime(x);
23 std::cout << p << std::endl;