From the Einstein's photoelectric equation,
⇒ Kinetic energy = Energy of Photon - Work Function
Let ϕ0 be the work function or metal and v1 and v2 be the velocity of photoelectrons. Using Einsteins photoelectric equation we have
12mv21=4−ϕ0 ....(i)
12mv22=2.5−ϕ0 ....(ii)
⇒12mv2112mv22=4−ϕ02.5−ϕ0
⇒(2)2=4−ϕ02.5−ϕ0⇒10−4ϕ0=4−ϕ0
⇒ϕ0=2 eV