reserve i,j,k,n,m for Nat,
        X for set,
        b,s for bag of X,
        x for object;
reserve O for Ordinal,
        R for right_zeroed add-associative right_complementable
          right_unital distributive non trivial doubleLoopStr,
        p for Polynomial of O, R;
reserve O for Ordinal,
        R for right_zeroed add-associative right_complementable
             right_unital distributive non trivial doubleLoopStr,
        p for Polynomial of O, R;

theorem Th60:
  for f be finite Function st f is with_evenly_repeated_values
    holds count_reps(f,n).x is even
proof
  let f be finite Function such that
A1:f is with_evenly_repeated_values;
A2: dom count_reps(f,n) = n by PARTFUN1:def 2;
  per cases;
  suppose
A3: x in n;
    then x in Segm n;
    then reconsider i=x as Nat;
    count_reps(f,n).i = card (f"{i+1}) by Def8,A3;
    hence thesis by A1,HILB10_7:def 6;
  end;
  suppose not x in n;
    hence thesis by A2,FUNCT_1:def 2;
  end;
end;
