import java.util.Scanner;

class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		
		int[] a = new int[N];
		for(int i=0; i<N; i++){
			a[i] = sc.nextInt();
		}

		int cnt = 0;
		int cnt2 = 0;

		boolean hasGray = false;
		boolean hasBrown = false;
		boolean hasGreen = false;
		boolean hasWater = false;
		boolean hasBlue = false;
		boolean hasYellow = false;
		boolean hasOrange = false;
		boolean hasRed = false;

		for(int i=0; i<N; i++){
			if(a[i]<=399){
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			}else if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			}
		}

		if(cnt==0){
			cnt = 1;
			cnt2 = cnt2 - 1;
		}

		System.out.println(cnt + " " + (cnt + cnt2));

	}

} import java.util.Scanner; Scanner java.util class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		
		int[] a = new int[N];
		for(int i=0; i<N; i++){
			a[i] = sc.nextInt();
		}

		int cnt = 0;
		int cnt2 = 0;

		boolean hasGray = false;
		boolean hasBrown = false;
		boolean hasGreen = false;
		boolean hasWater = false;
		boolean hasBlue = false;
		boolean hasYellow = false;
		boolean hasOrange = false;
		boolean hasRed = false;

		for(int i=0; i<N; i++){
			if(a[i]<=399){
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			}else if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			}
		}

		if(cnt==0){
			cnt = 1;
			cnt2 = cnt2 - 1;
		}

		System.out.println(cnt + " " + (cnt + cnt2));

	}

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		
		int[] a = new int[N];
		for(int i=0; i<N; i++){
			a[i] = sc.nextInt();
		}

		int cnt = 0;
		int cnt2 = 0;

		boolean hasGray = false;
		boolean hasBrown = false;
		boolean hasGreen = false;
		boolean hasWater = false;
		boolean hasBlue = false;
		boolean hasYellow = false;
		boolean hasOrange = false;
		boolean hasRed = false;

		for(int i=0; i<N; i++){
			if(a[i]<=399){
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			}else if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			}
		}

		if(cnt==0){
			cnt = 1;
			cnt2 = cnt2 - 1;
		}

		System.out.println(cnt + " " + (cnt + cnt2));

	} main {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		
		int[] a = new int[N];
		for(int i=0; i<N; i++){
			a[i] = sc.nextInt();
		}

		int cnt = 0;
		int cnt2 = 0;

		boolean hasGray = false;
		boolean hasBrown = false;
		boolean hasGreen = false;
		boolean hasWater = false;
		boolean hasBlue = false;
		boolean hasYellow = false;
		boolean hasOrange = false;
		boolean hasRed = false;

		for(int i=0; i<N; i++){
			if(a[i]<=399){
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			}else if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			}
		}

		if(cnt==0){
			cnt = 1;
			cnt2 = cnt2 - 1;
		}

		System.out.println(cnt + " " + (cnt + cnt2));

	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc int[] a = new int[N]; a new int[N] N for(int i=0; i<N; i++){
			a[i] = sc.nextInt();
		} int i=0; int i=0; i 0 i<N i N i++ i++ i {
			a[i] = sc.nextInt();
		} {
			a[i] = sc.nextInt();
		} a[i] = sc.nextInt() a[i] a i sc.nextInt() sc.nextInt sc int cnt = 0; cnt 0 int cnt2 = 0; cnt2 0 boolean hasGray = false; hasGray false boolean hasBrown = false; hasBrown false boolean hasGreen = false; hasGreen false boolean hasWater = false; hasWater false boolean hasBlue = false; hasBlue false boolean hasYellow = false; hasYellow false boolean hasOrange = false; hasOrange false boolean hasRed = false; hasRed false for(int i=0; i<N; i++){
			if(a[i]<=399){
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			}else if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			}
		} int i=0; int i=0; i 0 i<N i N i++ i++ i {
			if(a[i]<=399){
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			}else if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			}
		} {
			if(a[i]<=399){
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			}else if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			}
		} if(a[i]<=399){
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			}else if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			} a[i]<=399 a[i] a i 399 {
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			} if(!hasGray){
					cnt++;
					hasGray = true;
				} !hasGray hasGray {
					cnt++;
					hasGray = true;
				} cnt++ cnt hasGray = true hasGray true if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			} a[i]<=799 a[i] a i 799 {
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			} if(!hasBrown){
					cnt++;
					hasBrown = true;
				} !hasBrown hasBrown {
					cnt++;
					hasBrown = true;
				} cnt++ cnt hasBrown = true hasBrown true if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			} a[i]<=1199 a[i] a i 1199 {
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			} if(!hasGreen){
					cnt++;
					hasGreen = true;
				} !hasGreen hasGreen {
					cnt++;
					hasGreen = true;
				} cnt++ cnt hasGreen = true hasGreen true if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			} a[i]<=1599 a[i] a i 1599 {
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			} if(!hasWater){
					cnt++;
					hasWater = true;
				} !hasWater hasWater {
					cnt++;
					hasWater = true;
				} cnt++ cnt hasWater = true hasWater true if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			} a[i]<=1999 a[i] a i 1999 {
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			} if(!hasBlue){
					cnt++;
					hasBlue = true;
				} !hasBlue hasBlue {
					cnt++;
					hasBlue = true;
				} cnt++ cnt hasBlue = true hasBlue true if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			} a[i]<=2399 a[i] a i 2399 {
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			} if(!hasYellow){
					cnt++;
					hasYellow = true;
				} !hasYellow hasYellow {
					cnt++;
					hasYellow = true;
				} cnt++ cnt hasYellow = true hasYellow true if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			} a[i]<=2799 a[i] a i 2799 {
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			} if(!hasOrange){
					cnt++;
					hasOrange = true;
				} !hasOrange hasOrange {
					cnt++;
					hasOrange = true;
				} cnt++ cnt hasOrange = true hasOrange true if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			} a[i]<=3199 a[i] a i 3199 {
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			} if(!hasRed){
					cnt++;
					hasRed = true;
				} !hasRed hasRed {
					cnt++;
					hasRed = true;
				} cnt++ cnt hasRed = true hasRed true {
					cnt2++;
			} cnt2++ cnt2 if(cnt==0){
			cnt = 1;
			cnt2 = cnt2 - 1;
		} cnt==0 cnt 0 {
			cnt = 1;
			cnt2 = cnt2 - 1;
		} cnt = 1 cnt 1 cnt2 = cnt2 - 1 cnt2 cnt2 - 1 cnt2 1 System.out.println(cnt + " " + (cnt + cnt2)) System.out.println System.out System System.out cnt + " " + (cnt + cnt2) cnt + " " + (cnt + cnt2) cnt " " (cnt + cnt2) cnt cnt2 String[] args args
import java.util.Scanner;

class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		
		int[] a = new int[N];
		for(int i=0; i<N; i++){
			a[i] = sc.nextInt();
		}

		int cnt = 0;
		int cnt2 = 0;

		boolean hasGray = false;
		boolean hasBrown = false;
		boolean hasGreen = false;
		boolean hasWater = false;
		boolean hasBlue = false;
		boolean hasYellow = false;
		boolean hasOrange = false;
		boolean hasRed = false;

		for(int i=0; i<N; i++){
			if(a[i]<=399){
				if(!hasGray){
					cnt++;
					hasGray = true;
				}
			}else if(a[i]<=799){
				if(!hasBrown){
					cnt++;
					hasBrown = true;
				}
			}else if(a[i]<=1199){
				if(!hasGreen){
					cnt++;
					hasGreen = true;
				}
			}else if(a[i]<=1599){
				if(!hasWater){
					cnt++;
					hasWater = true;
				}
			}else if(a[i]<=1999){
				if(!hasBlue){
					cnt++;
					hasBlue = true;
				}
			}else if(a[i]<=2399){
				if(!hasYellow){
					cnt++;
					hasYellow = true;
				}
			}else if(a[i]<=2799){
				if(!hasOrange){
					cnt++;
					hasOrange = true;
				}
			}else if(a[i]<=3199){
				if(!hasRed){
					cnt++;
					hasRed = true;
				}
			}else{
					cnt2++;
			}
		}

		if(cnt==0){
			cnt = 1;
			cnt2 = cnt2 - 1;
		}

		System.out.println(cnt + " " + (cnt + cnt2));

	}

}
