def main():
    n = int(input())
    a = [int(i) for i in input().split()]
    ans = solve(n, a)
    print(*ans)


def solve(n, a):
    m = 8
    colors = [0 for i in range(m + 1)]
    for i in range(n):
        for j in range(m):
            if a[i] < 400 * (j + 1):
                colors[j] += 1
                break
        else:
            colors[m] += 1
    usedcolors = sum([1 for i in colors[:m] if i > 0])
    ans = [max(1,usedcolors), min(usedcolors + colors[m])]

    return ans


if __name__ == '__main__':
    main()