They cast lots for each temple gate according to their ancestral families, young and old alike.