Particle dynamics, Newton laws

A charged particle (mass , charge ) is at rest in an homogeneous magnetic field . Suddenly, at an electric field is switched on. The electric field is suddenly switched off at , where . Describe the motion of the particle. What is its final energy ?