title: Python: TypeError: 'NoneType' object has no attribute '__getitem__'
body: <p>When I was trying to run this:</p>
  
  <pre><code>lista=[4,10,4,15,6,15,18,10,7]
  listb=[5,10,5,18,11,35,21,10,7]
  
  import math
  
  for i in range(9):
      a=math.log10(lista[i])
      b=math.log10(listb[i])
      lista=lista.insert(i,a)
      listb=listb.insert(i,b)
  
  for i in range(17,8,-1):
      lista.remove(lista[i])
      listb.remove(listb[i])
  
  print(lista)
  print(listb)
  </code></pre>
  
  <p>Then I got :</p>
  
  <pre><code>File "C:/Python27/Lib/site-packages/xy/untitled3.py", line 11, in &lt;module&gt;
     a=math.log10(lista[i])
  TypeError: 'NoneType' object has no attribute '__getitem__'
  </code></pre>
  
  <p>I need help. Thank you very much</p>