import sys
#input = sys.stdin.readline
#sys.setrecursionlimit(10**6)
#from collections import Counter
#from copy import deepcopy
#from itertools import combinations
#from operator import itemgetter
#from copy import deepcopy
#from operator import mul
#from functools import reduce

def main():
    n = int(input())
    a = list(map(int, input().split()))
    colors = [0] * 8
    over3200 = 0
    for ia in a:
        if ia < 3200:
            colors[ia // 400] = 1
        else:
            over3200 += 1

    if sum(colors) == 0:
        r_min = 0
        r_max = over3200
    else:
        r_min = sum(colors)
        r_max = min(8, sum(colors) + over3200)
    print(r_min, r_max)


if __name__ == '__main__':
    main()
