Sahih Muslim , Book 4, Hadith 881 (USC-MSA) ⓘ
It was narrated from Abu Huraira that the Messenger of Allah said: The best rows for men are the first rows, and the worst ones the last ones, and the best rows for women are the last ones and the worst ones for them are the first ones.
حَدَّثَنَا زُهَيْرُ بْنُ حَرْبٍ، حَدَّثَنَا جَرِيرٌ، عَنْ سُهَيْلٍ، عَنْ أَبِيهِ، عَنْ أَبِي هُرَيْرَةَ، قَالَ قَالَ رَسُولُ اللَّهِ صلى الله عليه وسلم " خَيْرُ صُفُوفِ الرِّجَالِ أَوَّلُهَا وَشَرُّهَا آخِرُهَا وَخَيْرُ صُفُوفِ النِّسَاءِ آخِرُهَا وَشَرُّهَا أَوَّلُهَا " .
also referenced under: Book 4, Hadith 147 (In-Book) & Hadith 440 (Reference)