reorder lines for readbility