title: Trying to make a KML file in Python
body: <p>I'm still very new to python, i am trying to export the locations on a list (List2) into a kml file which will then display the results on google maps. I have no idea really what i am doing and atm all i am getting is a syntax error around every ,", symbol. Can someone help me with this please.</p>
  
  <pre><code>KMLFile = open("KML.txt", "w")
  f.write("&lt;KML_File&gt;\n")
  f.write("&lt;Document&gt;\n")
  for line in List2:
      f.write("   &lt;Placemark&gt;")
      f.write("       &lt;decription&gt;" + str(row[0]) + "&lt;/description&gt;")
      f.write("       &lt;Point&gt;")
      f.write("          &lt;coordinates&gt;" + str(row[2]) + str(row[1])"&lt;/coordinates&gt;")
      f.write("       &lt;/Point&gt;")
      f.write("   &lt;/Placemark&gt;")
  f.write("&lt;/Document&gt;\n")
  f.write("&lt;/kml&gt;\n")
  KMLFile = close()
  </code></pre>