Constraint on at least N unique digits in array

In reply to dave_59:

should this be following?


foreach (unum[i]) num.sum() with (4'(item==unum[i])) >= 1;