function Main(input){
  var In = input.split('\n').map(Number);
  var mochi = [];
  var count = 0;
  var a = 0;
  
  for(var i = 1; i<= In[0]; i++){
    mochi.push(In[i]);
  }
  
  mochi.sort(function(a,b){return a-b;});
  
  for(var j = 0; j < In[0]; j++){
    if(mochi[j] > a){
      count += 1;
      a = mochi[j];
    } else {
      break;
    }
  }
  
  console.log(count);
}

Main(require("fs").readFileSync("/dev/stdin", "utf8"));