Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- my_file = open('RandomDoc.bin', 'wb+')
- string = 'This is good.'
- asc_code = string.encode('ASCII')
- my_file.write(asc_code)
- my_file.close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement