title: How to concatenate 'str' and 'list' objects in python?
body: <p>I'm writing a python program.</p>
  <pre><code>fns = [10,20,30,40,45,49,51,54,57]
  file1=&quot;/run/media/john/Seagate Expansion Drive/cosmo-sim_9/RD00&quot;
  file2=&quot;/RedshiftOutput00&quot;
  for i, fn in enumerate(fns):
      fn=file1+fns+file2+fns # parameter file to load
      print fn
  </code></pre>
  <p>I am getting the following error.</p>
  <blockquote>
  <p>fn=file1+fns+file2+fns # parameter file to load</p>
  <p>TypeError: cannot concatenate 'str' and 'list' objects</p>
  </blockquote>
  <p>How to get rid of this? I want to load different files according to the numbers in the list.</p>
  <p>Thank You.</p>