title: Reading a file line by line into elements of an array in Python
body: <p>So in Ruby I can do the following:</p>
  
  <pre><code>testsite_array = Array.new
  y=0
  File.open('topsites.txt').each do |line|
  testsite_array[y] = line
  y=y+1
  end
  </code></pre>
  
  <p>How would one do that in Python?</p>