The Prophet ﷺ said, "The younger should greet the older, the one passing by should greet the one sitting, and the smaller group should greet the larger group."He said, this is a hasan sahih hadith.
حدثنا سويد بن نصر أنبأنا عبد الله بن المبارك أنبأنا معمر عن همام بن منبه
عن النبي ﷺ قال يسلم الصغير على الكبير والمار على القاعد والقليل على الكثير قال وهذا حديث حسن صحيح