=> 5^2n - 1
=> (5^2n - 1^2n)
=> (5^n - 1)*(5^n + 1)
(To prove above equation is divisible by 24, we can prove it is divisible by 2*3*4, as 2*3*4 = 24)
If you see above equation, this is one less than from 5^n and one more than 5^n. 5^n will be always and odd number, because 5 is an odd number and multiplication of two odd numbers are always odd number. So above two numbers will be always even numbers (odd number is always in between two even numbers) which will be two consecutive even number. If we take any two consecutive even numbers, one of them will be divisible by 2 and one will be divisible by 4. Now we need to prove it should be divisible by 3 as well.
If we take any three consecutive numbers, one of them will be divisible by 3. (5^n - 1), 5^n, (5^n + 1) are three consecutive numbers so one of them will be divisible by 3, in which 5^n is not divisible by 3, because it is only divisible by 5, so from remaining two numbers one of them will be divisible by 3.
So overall above expression is divisible by 2, 3 and 4 that means it will be divisible by 24.