N = int(input())
A = list(map(int, input().split()))
count = 0

for i in range(N-2):
  for j in range(i+1,N-1):
    for k in range(j+1,N):
      if A[i] != A[j] and A[j] != A[k] and A[k] != A[i] and (A[i] + A[j]>A[k]) and (A[j] + A[k]>A[i]) and (A[k] + A[i]>A[j]):
        count = count + 1

print(count)
 N = int(input()) N int(input()) int input() input A = list(map(int, input().split())) A list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split count = 0 count 0 for i in range(N-2):
  for j in range(i+1,N-1):
    for k in range(j+1,N):
      if A[i] != A[j] and A[j] != A[k] and A[k] != A[i] and (A[i] + A[j]>A[k]) and (A[j] + A[k]>A[i]) and (A[k] + A[i]>A[j]):
        count = count + 1 i range(N-2) range N-2 N 2 for j in range(i+1,N-1):
    for k in range(j+1,N):
      if A[i] != A[j] and A[j] != A[k] and A[k] != A[i] and (A[i] + A[j]>A[k]) and (A[j] + A[k]>A[i]) and (A[k] + A[i]>A[j]):
        count = count + 1 j range(i+1,N-1) range i+1 i 1 N-1 N 1 for k in range(j+1,N):
      if A[i] != A[j] and A[j] != A[k] and A[k] != A[i] and (A[i] + A[j]>A[k]) and (A[j] + A[k]>A[i]) and (A[k] + A[i]>A[j]):
        count = count + 1 k range(j+1,N) range j+1 j 1 N if A[i] != A[j] and A[j] != A[k] and A[k] != A[i] and (A[i] + A[j]>A[k]) and (A[j] + A[k]>A[i]) and (A[k] + A[i]>A[j]):
        count = count + 1 A[i] != A[j] and A[j] != A[k] and A[k] != A[i] and (A[i] + A[j]>A[k]) and (A[j] + A[k]>A[i]) and (A[k] + A[i]>A[j]) A[i] != A[j] and A[j] != A[k] and A[k] != A[i] and (A[i] + A[j]>A[k]) and (A[j] + A[k]>A[i]) A[i] != A[j] and A[j] != A[k] and A[k] != A[i] and (A[i] + A[j]>A[k]) A[i] != A[j] and A[j] != A[k] and A[k] != A[i] A[i] != A[j] and A[j] != A[k] A[i] != A[j] A[i] A i A[j] A j A[j] != A[k] A[j] A j A[k] A k A[k] != A[i] A[k] A k A[i] A i A[i] + A[j]>A[k] A[i] + A[j] A[i] A i A[j] A j A[k] A k A[j] + A[k]>A[i] A[j] + A[k] A[j] A j A[k] A k A[i] A i A[k] + A[i]>A[j] A[k] + A[i] A[k] A k A[i] A i A[j] A j count = count + 1 count count + 1 count 1 print(count) print count A = list(map(int, input().split())) list(map(int, input().split())) A count = 0 0 count count = count + 1 count + 1 count N = int(input()) int(input()) N
N = int(input())
A = list(map(int, input().split()))
count = 0

for i in range(N-2):
  for j in range(i+1,N-1):
    for k in range(j+1,N):
      if A[i] != A[j] and A[j] != A[k] and A[k] != A[i] and (A[i] + A[j]>A[k]) and (A[j] + A[k]>A[i]) and (A[k] + A[i]>A[j]):
        count = count + 1

print(count)

