Mathematics · Interactive tool
Integer Arithmetic and Next Prime
Calculate exact gcd, lcm, factorial or a bounded next-prime search.
Your inputs
Result
Calculated output
Enter inputs to calculate.
gcd(a,b) is the greatest nonnegative common divisor; lcm(a,b)=|ab|/gcd(a,b), with lcm(0,b)=0. n! = 1×2×...×n and 0!=1.
Factorials accept integers 0–1000. Next-prime search accepts n from 0 to 10^12 and returns the first prime p>n.