David counted the soldiers who were with him and appointed captains of thousands and captains of hundreds over them.