#Variable declaration
Z = 2.
#Calculations
#At ground state
n1=n2 =1
Eg = -(Z**2*13.6/n1**2)-(Z**2*13.6/n2**2)
#At first excited state
n1=1
n2=2
Ef = -(Z**2*13.6/n1**2)-(Z**2*13.6/n2**2)
#Result
print "Energy at ground state is %.f eV"%Eg
print "Energy at first excited state is %d eV"%Ef
#Variable declaration
Z=[16, 8, 3]
#Calculations&Results
#Argon numbers
n = 1
for x in range(len(Z)):
E=(-((Z[x])/n)**2)*13.6
print "The electric field for n=%d is %.1f ev"%(n, E)
n+=1
#Answer differnce is because of round off
#Variable declaration
Z=92
n=2
#Calculations
E=((Z/n)**2)*13.6#in ev
#Result
print "The ionization energy is %.e ev"%E
#Calculations&Results
#Energy of K shell
z=26
k=2
E_k=13.6*(z-k)**2#in ev
v=7.8*10**3#in V
#for L shell
l=10
E_l=13.6*(z-l)**2#in ev
h=E_k-E_l
R_m=1.1*10**7
x=R_m*(z-2)**2#x=1/lamda
lamba=1/x
print "The wavelength is %.1e m"%lamba
#Variable declaration
#Energy of K shell
z=82
k=2
#Calculations
E_k=13.6*(z-k)**2#in ev
#Result
print "The energy of K shell is %.1e eV"%E_k