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

cr = []
MAxans = 0

for i in A:
    c = i // 400
    if c < 8 and not c in cr:
        cr.append(c)
    elif c >= 8:
        MAxans += 1

Minans = len(cr)
MAxans = min(8, MAxans + Minans)

print(str(Minans) + " " + str(MAxans))