max_pairs
if (max_pairs == -1) {
COLOR_PAIRS = (max_pairs > MAX_PAIRS - 1 ?
MAX_PAIRS - 1 : max_pairs);
if (max_colors > 0 && max_pairs > 0 &&