Data source: http://rosettacode.org/wiki/Append_a_record_to_the_end_of_a_text_file
