rearranged output file