changes notes to a text file and completed to ex16.rb