import std.algorithm;
import std.array;
import std.conv;
import std.math;
import std.range;
import std.stdio;
import std.string;
import std.typecons;

T read(T)() { return readln.chomp.to!T; }
T[] reads(T)() { return readln.split.to!(T[]); }
alias readint = read!int;
alias readints = reads!int;

const RED_OVER_INDEX = 8;

int score2index(int score) {
    foreach (i, s; [400, 800, 1200, 1600, 2000, 2400, 2800, 3200]) {
        if (score < s) {
            return cast(int)i;
        }
    }
    return RED_OVER_INDEX;
}

void main() {
    readint;
    auto a = readints;

    auto d = new int[9];
    foreach (x; a) {
        d[score2index(x)]++;
    }

    int x = cast(int) d[0..RED_OVER_INDEX].count!(e => e > 0);
    int minAns = x;
    int maxAns = x;
    int zero = cast(int) d[0..RED_OVER_INDEX].count!(e => e == 0);

    if (d[RED_OVER_INDEX] > 0) {
        if (minAns == 0) minAns++;

        maxAns += d[RED_OVER_INDEX];
    }

    writeln(minAns, " ", maxAns);
}
