Skip to content

Instantly share code, notes, and snippets.

@bngsudheer
Created April 29, 2017 14:22
Show Gist options
  • Save bngsudheer/9ebfedbaa1f71d514cf744893af8d2f9 to your computer and use it in GitHub Desktop.
Save bngsudheer/9ebfedbaa1f71d514cf744893af8d2f9 to your computer and use it in GitHub Desktop.
import time
string_to_add = 'my_new_characters'
file_name = 'my_file.{}'.format(time.time())
file_name = '{}{}'.format(file_name, string_to_add)
with open(file_name, 'w') as outfile:
outfile.write('hello')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment