Created
October 3, 2013 23:49
-
-
Save studiawan/6818891 to your computer and use it in GitHub Desktop.
Write to text file using Python
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
data = 'Beautiful Python' | |
f = open('file.txt', 'w') | |
f.write(data) | |
f.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment