To find the LCM (Least Common Multiple) of two numbers then multiply both numbers by 1,2,3 and so on and so on.
6 x 1 = 6
6 x 2 = 12
6 x 3 = 18
6 x 4 = 24
6 x 5 = 30
===================================================================
8 x 1 = 8
8 x 2 = 16
8 x 3 = 24
8 x 4 = 32
8 x 5 = 40
Now find the multiple that matches first (which is 24)
Your LCM is 24