#define _GLIBCXX_DEBUG
#include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (n); ++i)
#define REPS(I, a, b) for (int i = (a); i < (b); ++i)
using namespace std;
using ll = long long;

int main() {
  int n;
  cin >> n;
  vector<int> a(n,0);  
  REP(i,n) cin >> a[i];
  
  sort(a.begin(), a.end());
  
  bool ok = true;
  REP(i,n){
    if(i != n-1){
      if(a[i] == a[i+1]){
        ok = false;
      }
    }
  }
  
  
  if(ok) cout << "YES" << endl;
  else cout << "NO" << endl;
  


}
//\\//\\ * * * //\\// ||
#include <bits/stdc++.h> 

#define debug(x) cerr << #x << ": " << x << endl

using namespace std;

typedef long long ll;

const int N = 110;

int a[N];

int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  sort(a, a + n);
  int ans = 0;
  for (int i = 0; i < n; i++) {
    for (int j = i + 1; j < n; j++) {
      for (int k = j + 1; k < n; k++) {
        if (a[i] != a[j] && a[i] != a[k] && a[j] != a[k]) {
          if (a[i] + a[j] > a[k]) {
            ++ans;
//            debug(i);
//            debug(j);
//            debug(k);
//            debug(a[i]);
//            debug(a[j]);
//            debug(a[k]);
          }
        } 
      }
    }
  }
  cout << ans << '\n';
  return 0;
}
