Improved file readability and added some comments