import math
#Variable decalaration
pd = 100 #potential difference, V
m0=9.11*(10**-31);#m0=rest mass of the electron in kg
#Calculations&Results
#solving final velocity of the electron
Ek=1.6*(10**-19)*pd;#Ek=final kinetic energy of electron in Joules
print "Final kinetic energy = %.1e J,%.f eV"%(Ek,Ek*6.242*10**18)
v=math.sqrt((2*Ek)/m0)#v=final velocity of the electron
print "Final velocity = %.3e m/s"%v
import math
#Variable declaration
m=7360*9.11*(10**-31);#m=mass of the ion in kg
q=2*1.6*(10**-19);#q=charge of the ion in Coulomb
V=2000;#V=potential difference in Volt
#Calculations&Results
#solving velocity & kinetic energy of the ion
v=math.sqrt((2*q*V)/m)#v=velocity of the ion
print "Velocity acquired by the ion = %.3e m/s"%v
Ek=(1./2)*m*(v**2)#Ek=kinetic energy of the ion
print "Kinetic energy of ion = %.1e J = %.f eV"%(Ek,Ek*6.242*10**18)