It is narrated from Sayyiduna Abu Hurairah (may Allah be pleased with him) that the Noble Prophet (peace and blessings be upon him) said: "The best rows for men are the first ones and the worst are the last ones, (whereas) the best rows for women are the last ones and the worst are the first ones."
Hadith Referenceالسنن المأثورة / باب ما جاء في فضل النبي ﷺ والصلاة عليه / 177
Hadith Takhrijصحیح مسلم، الصلاة، باب تسوية الصفوف و اقامتها وفضل رقم : 440 ۔