3With the help of Eleazar’s descendant Zadok and Ithamar’s descendant Ahimelech, David divided them according to the offices of their service.
4Since more leaders were found among Eleazar’s descendants than those of Ithamar, they were divided accordingly. There were sixteen heads of families from the descendants of Eleazar and eight from the descendants of Ithamar.
5Thus they were divided by lot, for there were officers of the sanctuary and officers of God among both Eleazar’s and Ithamar’s descendants.
6The scribe, Shemaiah son of Nethanel, a Levite, recorded their names in the presence of the king and of the officers: Zadok the priest, Ahimelech son of Abiathar, and the heads of families of the priests and the Levites — one family being taken from Eleazar, and then one from Ithamar.
— 1 Chronicles 24:3-6