I've got to make a program which creates a file at the beginning and then overwrite it. I've got something like this below and It works, but I wondered if there is a possibility to ask user where It should be created? For example just like It's done in MS Office?
# -*- coding: utf-8 -*-
import os.path
path = ('C:\\Python27\\')
name = raw_input('Enter file name: ')
save = os.path.join(path, name+'.txt')
save2 = open(save , 'a')
contents = raw_input('Contents')
save2.write(contents)
save2.close()