#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;i < n;++i) { int idx; 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 tn, hn, mx = 0; tn = hn = n;
        
        while (tn && hn) {
            bool flag = true;
            
            for(int i=0;i < n;++i) {
                if (t[i] && mx < t[i]) {
                    mx = t[i]; --tn; t[i] = 0;
                    flag = false;
                    break;
                }
            }
            
            if (!tn || !hn) break;
            if (flag) mx = 0;
            
            flag = true;
            
            for(int i=0;i < n;++i) {
                if (h[i] && mx < h[i]) {
                    mx = h[i]; --hn; h[i] = 0;
                    flag = false;
                    break;
                }
            }
            
            if (flag) mx = 0;
        }

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

    return 0;
}