import numpy as np

n = int(input())
a = np.array(list(map(int, input().split())))

c = np.where(a < 3200, a//400, 8)
j = np.count_nonzero(c == 8)
Mans = max(8, len(np.unique(c)) - 1 + j) if j else len(np.unique(c))
mans = max(1, len(np.unique(c)) - 1) if j else len(np.unique(c))
print(mans, Mans)