Utilities for combinatorics