memTime = int(input())
memLate = input().split()
# memTime = int(input())
# memLate = input().split()
memLate = [int(i) for i in memLate]
colorList = []
memColor = 0
highLate = 0
for color in memLate:
    if color // 400 >= 8:
        highLate += 1
    elif (color // 400) in colorList == False:
        colorList += color // 400
maxColor = len(colorList) + highLate
print(str(len(colorList)) + " " + str(maxColor))