title: Include changing variables into name of output file in Python
body: <p>I'm new to Python (and programming), so bear with me if I ask really stupid questions :)</p>
  
  <p>So, I want to include variables in the filename of the results. This is what I have so far:</p>
  
  <pre><code>resfile = open("simple.csv","w")
  #lots of stuff of no relevance
  
  resfile.close()
  </code></pre>
  
  <p>In the script I have two variables, minLenght=5000 and minBF=10, but I want to change them and run the script again creating a new file where I can see the number of the variables in the title of the file created, e.g. simple500010 and I want a new file created everytime I run the script with different values for the two variables.</p>
  
  <p>I tried this:</p>
  
  <pre><code>resfile = open("simple" + [str(minLength)] + [str(minBF)].csv,"w")
  </code></pre>
  
  <p>But that doesn't work.</p>
  
  <p>Any ideas?</p>