Almost corrected the output as a group