N=int(input())
Ls = list(map(int,input().split()))
score=0
for i in range(0,N-2):
  a = Ls[i]
  for j in range(i+1, N-1):
      b = Ls[j]
      for k in range(j+1, N):
        c = Ls[k]
        if ((a+b>c)&(a+c>b)&(b+c>a)&(a!=b)&(a!=c)&(b!=c)):
          score+=1

print(score) N=int(input()) N int(input()) int input() input Ls = list(map(int,input().split())) Ls list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split score=0 score 0 for i in range(0,N-2):
  a = Ls[i]
  for j in range(i+1, N-1):
      b = Ls[j]
      for k in range(j+1, N):
        c = Ls[k]
        if ((a+b>c)&(a+c>b)&(b+c>a)&(a!=b)&(a!=c)&(b!=c)):
          score+=1 i range(0,N-2) range 0 N-2 N 2 a = Ls[i] a Ls[i] Ls i for j in range(i+1, N-1):
      b = Ls[j]
      for k in range(j+1, N):
        c = Ls[k]
        if ((a+b>c)&(a+c>b)&(b+c>a)&(a!=b)&(a!=c)&(b!=c)):
          score+=1 j range(i+1, N-1) range i+1 i 1 N-1 N 1 b = Ls[j] b Ls[j] Ls j for k in range(j+1, N):
        c = Ls[k]
        if ((a+b>c)&(a+c>b)&(b+c>a)&(a!=b)&(a!=c)&(b!=c)):
          score+=1 k range(j+1, N) range j+1 j 1 N c = Ls[k] c Ls[k] Ls k if ((a+b>c)&(a+c>b)&(b+c>a)&(a!=b)&(a!=c)&(b!=c)):
          score+=1 (a+b>c)&(a+c>b)&(b+c>a)&(a!=b)&(a!=c)&(b!=c) (a+b>c)&(a+c>b)&(b+c>a)&(a!=b)&(a!=c) (a+b>c)&(a+c>b)&(b+c>a)&(a!=b) (a+b>c)&(a+c>b)&(b+c>a) (a+b>c)&(a+c>b) a+b>c a+b a b c a+c>b a+c a c b b+c>a b+c b c a a!=b a b a!=c a c b!=c b c score+=1 score 1 print(score) print score a = Ls[i] Ls[i] a c = Ls[k] Ls[k] c score=0 0 score N=int(input()) int(input()) N b = Ls[j] Ls[j] b Ls = list(map(int,input().split())) list(map(int,input().split())) Ls score+=1 1 score
N=int(input())
Ls = list(map(int,input().split()))
score=0
for i in range(0,N-2):
  a = Ls[i]
  for j in range(i+1, N-1):
      b = Ls[j]
      for k in range(j+1, N):
        c = Ls[k]
        if ((a+b>c)&(a+c>b)&(b+c>a)&(a!=b)&(a!=c)&(b!=c)):
          score+=1

print(score)