Ibn 'Abbas (May Allah be pleased with them) reported:
The Prophet (ﷺ) said, "The best number of companions is four; the best detachment is four hundred and the best army is four thousand; and twelve thousand men will not be defeated as a result of smallness of number."[At-Tirmidhi and Abu Dawud]. (PT)
App reference (PT): Book 8, Hadith 6 (PT)
Arabic/English book reference (PT): Book 8, Hadith 961 (PT)