Changing file read and adding some comments.