# An easy approach to find first non zero digit in (n!) - Gajen's Method

• Gajendra Kumar is a veteran educationist and has authored seven books related to Quant and LR. He co founded Pioneer Career and serves as the Dy Director (Academics) and Senior Math faculty for a premier IITJEE classes. This method was invented by Gajendra kumar and helps us to find the first non zero digit in n!. Gajendra Kumar received Copyright Certificate from Govt of India for this formula.

Let U[N!] is the first non zero digit in N!

Let Highest power of 5 in N! is P and R1, R2 etc are the remainders when N is successively divided by 5, then

U[N!] = U[2p] X U[R1!] X U[R2!] etc.

We will understand this by taking some examples.

Find first non zero digit of 14! Highest power of 5 in 14!, p = 2
Remainder when 14 is divided by 5, R1 = 4
Remainder when 2 ( as 14 = 2 * 5 + 4 ) is divided by 5, R2 = 2
R3, R4 etc are zero here as 2 = 0 * 5 + 2
so First non zero digit, U[14!] =
U X U[4!] X U[2!]
= U X U X U
U[4X4X2] = 2

Find first non zero digit of 137! Highest power of 5 in 137!, p = 27 + 5 + 1 = 33
U[137!] = U X U[2!] X U[2!] X U[0!] X U[1!]

We know in case of 2, unit digit repeats itself after a cycle of 4 . We will divide 33 by 4
33/4 remainder is 1
= > U = U =  2

U[137!] = U[2 X 2 X 2 X 1 X 1] = 8

Find first non zero digit of 222! Highest power of 5 in 222!, p = 44 + 8 + 1 + 0 = 53
U[222!] = U X U[2!] X U[4!] X U[3!] X U[1!]
Again cycicity of 2 is 4, and 53/4 remainder is 1
= > U = U =  2

U[222!] = U[2 X 2 X 4 X 6 X 1] = 6

1

1

1

1

1

1

1

1