Python Write to file

kced20 Feb 22nd, 2019 87 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # this line will open or create a text document called female.txt
  2. out = open("female.txt","w")
  3. # this line below will write Hello to female.txt
  4. out.write("Hello")
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand