#include <cstdio>
#include <iostream>
using namespace std;

int main()
{
    int n;
    while (cin >> n && n) {
        int t[100]={0}, h[100]={0}, c[200]={0};

        for(int i=0, idx;i < n;++i) { cin >> idx; c[idx-1] = 1; }

        for(int i=0,idx[2]={0};i < n*2;++i) {
            if (c[i]) t[idx[0]++] = i+1;
            else h[idx[1]++] = i+1;
        }

        int mx, tn, hn;
        tn = hn = n;
        mx = 0;

        while(tn && hn) {
            bool flag = true;
            for(int i=0;i < n;++i) {
                if (t[i] && mx < t[i]) {
                    mx = t[i]; t[i] = 0; --tn;
                    flag = false;
                    break;
                } 
            }
            
            if (!hn || !tn) break;
            else if (flag) mx = 0;

            flag = true;

            for(int i=0;i < n;++i) {
                if (h[i] && mx < h[i]) {
                    mx = h[i]; h[i] = 0; --hn;
                    flag = false;
                    break;
                }
            }

            if (flag) mx = 0;
        }

        printf("%d\n%d\n", hn, tn);
    }
    return 0;
}