Python 2.5.2 (r252:60911, Feb 22 2008, 07:57:53) [GCC 4.0.1 (Apple Computer, Inc. build 5363)] Type "help", "copyright", "credits" or "license" for more information. >>> Evaluating second_file_example.py Dear Aunt Myrtle, How are you? >>> file2 = open('story.txt') >>> s = file2.read(10) >>> s 'Once upon ' >>> s = file2.read(6) >>> s 'a time' >>> file2.read(20) ' there was a curious' >>> file2.read(10) ' little gi' >>> file2.read(10) 'rl\nnamed G' >>> filename = "story.txt" >>> my_file = open(filename) >>> my_file.read() 'Once upon a time there was a curious little girl\nnamed Goldilocks. Goldilocks lived near the woods\nand loved to go exploring.\n\nOne day Goldilocks \ncame upon a comfy little cottage.\nThe door was open, and she decided to take a peak \ninside.' >>> my_file = open(filename,'w') >>> my_file.write('help') >>> my_file.close() >>> my_file = open(filename,'a') >>> my_file.write('\nhelp again and again') >>> my_file.close() >>>