n = int(input())
a = list(map(int,input().split()))
t = [0] * 9

for i in range(n):
    if a[i] < 3200:
        t[a[i] // 400] += 1
    else:
        t[8] += 1

z = t.pop(8)
p = t.count(0)
amax = min(8,8-p+z)
if p == 8:
    amin = 1
else:
    amin = 8 - p

print(amin,amax)