def slove():
    import sys
    input = sys.stdin.readline
    ls = [0] * 9
    n = int(input().rstrip('\n'))
    a = list(map(int, input().rstrip('\n').split()))
    for v in a:
        if 1 <= v <= 399:
            ls[0] = 1
        elif 400 <= v <= 700:
            ls[1] = 1
        elif 800 <= v <= 1199:
            ls[2] = 1
        elif 1200 <= v <= 1599:
            ls[3] = 1
        elif 1600 <= v <= 1999:
            ls[4] = 1
        elif 2000 <= v <= 2399:
            ls[5] = 1
        elif 2400 <= v <= 2799:
            ls[6] = 1
        elif 2800 <= v <= 3199:
            ls[7] = 1
        else:
            ls[8] += 1
    print(max(sum(ls[:8]), 1), sum(ls[:8]) + ls[8])


if __name__ == '__main__':
    slove()
