Because std.bigint's member data is a private property, and there is no API setDigit that opens the opposite of getDigit, it can only be shifted by digits one by one. !! Here is a performance bottleneck.
Test whether BigInt n is prime. Step 1: millerRabinPrimeTest Step 2: lucasLehmerTest
Random generate a BigInt by bitLength.
Random generate a BigInt between min and max.