changed the output format to suit MR format (key-value pairs)