Least Common Multiple Calculator

BASIC MATH · EXACT BIGINT ARITHMETIC

Least Common Multiple (LCM)

Calculated on this device
Enter at least 2 whole integers separated by commas, up to 32 characters total.

LEAST COMMON MULTIPLE

72

LCM(12, 18, 24) = 72

Formula LCM(a, b) = (|a| ÷ GCD(|a|, |b|)) × |b| via Euclidean GCD

Companion GCF6Greatest common factor
Integers Parsed3Exact BigInt values

HOW IT WORKS

Finding the LCM via Euclidean GCD

The least common multiple (LCM) of two or more integers is the smallest non-negative integer that is evenly divisible by every number in the list.

01

Euclidean GCD reduction

Instead of listing multiples by brute force, the calculator computes the greatest common divisor first and divides before multiplying to prevent unnecessary intermediate growth:

LCM(a, b) = (|a| ÷ GCD(|a|, |b|)) × |b|
02

Associative folding for 3+ integers

For a list of integers, the two-argument formula folds left-to-right across the entire set:

LCM(a, b, c) = LCM(LCM(a, b), c)
03

Exact BigInt precision

Every step runs in arbitrary-precision BigInt integer arithmetic, avoiding the 53-bit precision ceiling of standard floating-point numbers.

LCM(12, 18, 24) = 72

LCM GUIDE

LCM vs. GCF, common denominators & prime factorization

Why LCM matters for fractions and scheduling

Finding the least common multiple is the fastest way to determine the least common denominator (LCD) when adding or subtracting fractions with different denominators. Outside arithmetic, LCM also solves repeating-cycle problems—such as finding when two or more periodic events coincide again.

Comparing LCM and GCF

While the LCM is at least as large as the largest non-zero input, the greatest common factor (GCF) is at most as large as the smallest non-zero input. For any two positive integers, their product equals LCM(a, b) × GCF(a, b) = a × b.

Need only the largest shared divisor? Use the GCF Calculator, inspect prime factors with the Factor Calculator, or add fractions directly with the Fraction Calculator.

Frequently asked questions

What is the LCM of two prime or coprime numbers?

When two integers share no common factors other than 1 (for example, 7 and 13), their GCF is 1, so their LCM is simply their product: 7 × 13 = 91.

Why is the LCM 0 if one of the numbers is 0?

Zero is a multiple of every integer (0 = k × 0), and the only multiple of 0 is 0 itself, so the least common multiple of 0 and any integer is 0.

Can I include negative integers?

Yes. The least common multiple is defined as non-negative, so negative inputs are normalized to their absolute values before computing the LCM.

How many numbers can I enter at once?

You can enter between 2 and 16 comma-separated integers within the 32-character input limit.

Your inputs are calculated in this browser and are not sent to a server.