Here, mass of bullet m =0.012 kg, initial speed of bullet « = 70 m, mass of wood block M =0.4 kg.
As on collision, the bullet comes to rest w.r.t. block, it means that after collision bullet and block are moving with a common speed v.
From conservation law of momentum mu = (M + m)v
v = mu / (M + m) = 0.012 x 70 / (0.4 + 0.012) = 2.04 m
If the block now rises to a maximum height of h, then using conservation law of mechanical energy, we have
h = 0.212m = 21.2 cm