Changed the format of output of the third script