LCM 40, HCF 1
5 and 8 are coprime

Check1 × 40 = 40 = 5 × 8

1. Listing multiples (LCM)

Multiples of 5: 5, 10, 15, 20, 25, 30, 35, 40
Multiples of 8: 8, 16, 24, 32, 40
The first one in both lists is 40.

2. Listing factors (HCF)

Factors of 5: 1, 5
Factors of 8: 1, 2, 4, 8
Common factors: 1, so the highest is 1.

3. Prime factors

5 = 5 and 8 = 2³. The HCF multiplies the primes they share, each to its lowest power: they share none, so it's 1. The LCM multiplies every prime, each to its highest power: 2³ × 5 = 40.

Euclid's method (HCF)

8 = 1 × 5 + 3; 5 = 1 × 3 + 2; 3 = 1 × 2 + 1; 2 = 2 × 1 + 0. The last number you divided by is the HCF: 1. Then LCM = 5 × 8 ÷ HCF = 40 ÷ 1 = 40.

Two or more numbers. The HCF is also called the GCF (greatest common factor) or GCD (greatest common divisor).

40
lowest common multiple (LCM)

Highest common factor (HCF)1 (they're coprime: no common factor but 1)
By prime factors5 = 5; 8 = 2³; HCF = 1, LCM = 2³ × 5
Check1 × 40 = 40 = 5 × 8

Frequently asked questions

What is the LCM of 5 and 8?

40: the smallest number that both 5 and 8 divide into exactly (40 = 5 × 8 = 8 × 5).

What is the HCF of 5 and 8?

1: the biggest number that divides both exactly. 5 and 8 have no common factor but 1, so they're coprime.

What is the GCF of 5 and 8?

1. The greatest common factor (GCF) is the same as the highest common factor (HCF).

Other pairs
Related calculators