n = int(input())
l = list(map(int, input().split()))
t = 0

for i in range(len(l)):
    for j in range(i + 1, len(l)):
        for k in range(j + 1, len(l)):
            sum = l[i] + l[j] + l[k]
            if sum - max(l[i], l[j], l[k]) > max(l[i], l[j], l[k]):
                if l[i] != l[j] and l[i] != l[k] and l[j] != l[k]:
                    t += 1

print(t) n = int(input()) n int(input()) int input() input l = list(map(int, input().split())) l list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split t = 0 t 0 for i in range(len(l)):
    for j in range(i + 1, len(l)):
        for k in range(j + 1, len(l)):
            sum = l[i] + l[j] + l[k]
            if sum - max(l[i], l[j], l[k]) > max(l[i], l[j], l[k]):
                if l[i] != l[j] and l[i] != l[k] and l[j] != l[k]:
                    t += 1 i range(len(l)) range len(l) len l for j in range(i + 1, len(l)):
        for k in range(j + 1, len(l)):
            sum = l[i] + l[j] + l[k]
            if sum - max(l[i], l[j], l[k]) > max(l[i], l[j], l[k]):
                if l[i] != l[j] and l[i] != l[k] and l[j] != l[k]:
                    t += 1 j range(i + 1, len(l)) range i + 1 i 1 len(l) len l for k in range(j + 1, len(l)):
            sum = l[i] + l[j] + l[k]
            if sum - max(l[i], l[j], l[k]) > max(l[i], l[j], l[k]):
                if l[i] != l[j] and l[i] != l[k] and l[j] != l[k]:
                    t += 1 k range(j + 1, len(l)) range j + 1 j 1 len(l) len l sum = l[i] + l[j] + l[k] sum l[i] + l[j] + l[k] l[i] + l[j] l[i] l i l[j] l j l[k] l k if sum - max(l[i], l[j], l[k]) > max(l[i], l[j], l[k]):
                if l[i] != l[j] and l[i] != l[k] and l[j] != l[k]:
                    t += 1 sum - max(l[i], l[j], l[k]) > max(l[i], l[j], l[k]) sum - max(l[i], l[j], l[k]) sum max(l[i], l[j], l[k]) max l[i] l i l[j] l j l[k] l k max(l[i], l[j], l[k]) max l[i] l i l[j] l j l[k] l k if l[i] != l[j] and l[i] != l[k] and l[j] != l[k]:
                    t += 1 l[i] != l[j] and l[i] != l[k] and l[j] != l[k] l[i] != l[j] and l[i] != l[k] l[i] != l[j] l[i] l i l[j] l j l[i] != l[k] l[i] l i l[k] l k l[j] != l[k] l[j] l j l[k] l k t += 1 t 1 print(t) print t t = 0 0 t t += 1 1 t n = int(input()) int(input()) n sum = l[i] + l[j] + l[k] l[i] + l[j] + l[k] sum l = list(map(int, input().split())) list(map(int, input().split())) l
n = int(input())
l = list(map(int, input().split()))
t = 0

for i in range(len(l)):
    for j in range(i + 1, len(l)):
        for k in range(j + 1, len(l)):
            sum = l[i] + l[j] + l[k]
            if sum - max(l[i], l[j], l[k]) > max(l[i], l[j], l[k]):
                if l[i] != l[j] and l[i] != l[k] and l[j] != l[k]:
                    t += 1

print(t)
