Added comments and fixed encoding