#include "primes.h" #include #include namespace NKikimr { static const unsigned long PRIMES[] = { #include "primes.gen" }; unsigned long FindNearestPrime(unsigned long num) { if (num <= *PRIMES) { return *PRIMES; } return *LowerBound(PRIMES, PRIMES + Y_ARRAY_SIZE(PRIMES) - 1, num); } }