function Main(input){
  input = input.split('\n');
  input.shift();
  input.pop();
  input = input.map((a)=>Number(a));
  var dnum = input.filter((a,b,c)=>c.indexOf(a)===b);
  console.log(dnum.length);
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));