import java.util.Scanner;

public 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[] sum = new int[9];
		for(int i = 0 ; i < n ; i++) {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		}
		int max = 0;
		int min = 0;
		int hatena = sum[8];
		for(int i = 0 ; i < 8 ; i++) {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		}
		if(min == 0) {
			System.out.println(1 + " " + hatena);
		} else {
			System.out.println(min + " " + (max + hatena));
		}
	}
} import java.util.Scanner; Scanner java.util public 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[] sum = new int[9];
		for(int i = 0 ; i < n ; i++) {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		}
		int max = 0;
		int min = 0;
		int hatena = sum[8];
		for(int i = 0 ; i < 8 ; i++) {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		}
		if(min == 0) {
			System.out.println(1 + " " + hatena);
		} else {
			System.out.println(min + " " + (max + hatena));
		}
	}
} 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[] sum = new int[9];
		for(int i = 0 ; i < n ; i++) {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		}
		int max = 0;
		int min = 0;
		int hatena = sum[8];
		for(int i = 0 ; i < 8 ; i++) {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		}
		if(min == 0) {
			System.out.println(1 + " " + hatena);
		} else {
			System.out.println(min + " " + (max + hatena));
		}
	} 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[] sum = new int[9];
		for(int i = 0 ; i < n ; i++) {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		}
		int max = 0;
		int min = 0;
		int hatena = sum[8];
		for(int i = 0 ; i < 8 ; i++) {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		}
		if(min == 0) {
			System.out.println(1 + " " + hatena);
		} else {
			System.out.println(min + " " + (max + hatena));
		}
	} 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] a i sc.nextInt() sc.nextInt sc int[] sum = new int[9]; sum new int[9] 9 for(int i = 0 ; i < n ; i++) {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		} int i = 0 ; int i = 0 ; i 0 i < n i n i++ i++ i {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		} {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		} if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++; 0 <= a[i] && a[i] < 400 0 <= a[i] 0 a[i] a i a[i] < 400 a[i] a i 400 sum[0]++ sum[0] sum 0 if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++; 400 <= a[i] && a[i] < 800 400 <= a[i] 400 a[i] a i a[i] < 800 a[i] a i 800 sum[1]++ sum[1] sum 1 if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++; 800 <= a[i] && a[i] < 1200 800 <= a[i] 800 a[i] a i a[i] < 1200 a[i] a i 1200 sum[2]++ sum[2] sum 2 if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++; 1200 <= a[i] && a[i] < 1600 1200 <= a[i] 1200 a[i] a i a[i] < 1600 a[i] a i 1600 sum[3]++ sum[3] sum 3 if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++; 1600 <= a[i] && a[i] < 2000 1600 <= a[i] 1600 a[i] a i a[i] < 2000 a[i] a i 2000 sum[4]++ sum[4] sum 4 if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++; 2000 <= a[i] && a[i] < 2400 2000 <= a[i] 2000 a[i] a i a[i] < 2400 a[i] a i 2400 sum[5]++ sum[5] sum 5 if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++; 2400 <= a[i] && a[i] < 2800 2400 <= a[i] 2400 a[i] a i a[i] < 2800 a[i] a i 2800 sum[6]++ sum[6] sum 6 if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++; 2800 <= a[i] && a[i] < 3200 2800 <= a[i] 2800 a[i] a i a[i] < 3200 a[i] a i 3200 sum[7]++ sum[7] sum 7 if(3200 <= a[i]) sum[8]++; 3200 <= a[i] 3200 a[i] a i sum[8]++ sum[8] sum 8 int max = 0; max 0 int min = 0; min 0 int hatena = sum[8]; hatena sum[8] sum 8 for(int i = 0 ; i < 8 ; i++) {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		} int i = 0 ; int i = 0 ; i 0 i < 8 i 8 i++ i++ i {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		} {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		} if(sum[i] >= 1) {
				max++;
				min++;
			} sum[i] >= 1 sum[i] sum i 1 {
				max++;
				min++;
			} max++ max min++ min if(min == 0) {
			System.out.println(1 + " " + hatena);
		} else {
			System.out.println(min + " " + (max + hatena));
		} min == 0 min 0 {
			System.out.println(1 + " " + hatena);
		} System.out.println(1 + " " + hatena) System.out.println System.out System System.out 1 + " " + hatena 1 + " " + hatena 1 " " hatena {
			System.out.println(min + " " + (max + hatena));
		} System.out.println(min + " " + (max + hatena)) System.out.println System.out System System.out min + " " + (max + hatena) min + " " + (max + hatena) min " " (max + hatena) max hatena String[] args args public 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[] sum = new int[9];
		for(int i = 0 ; i < n ; i++) {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		}
		int max = 0;
		int min = 0;
		int hatena = sum[8];
		for(int i = 0 ; i < 8 ; i++) {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		}
		if(min == 0) {
			System.out.println(1 + " " + hatena);
		} else {
			System.out.println(min + " " + (max + hatena));
		}
	}
} public 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[] sum = new int[9];
		for(int i = 0 ; i < n ; i++) {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		}
		int max = 0;
		int min = 0;
		int hatena = sum[8];
		for(int i = 0 ; i < 8 ; i++) {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		}
		if(min == 0) {
			System.out.println(1 + " " + hatena);
		} else {
			System.out.println(min + " " + (max + hatena));
		}
	}
} Main
import java.util.Scanner;

public 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[] sum = new int[9];
		for(int i = 0 ; i < n ; i++) {
			if(0 <= a[i] && a[i] < 400) sum[0]++;
			else if(400 <= a[i] && a[i] < 800) sum[1]++;
			else if(800 <= a[i] && a[i] < 1200) sum[2]++;
			else if(1200 <= a[i] && a[i] < 1600) sum[3]++;
			else if(1600 <= a[i] && a[i] < 2000) sum[4]++;
			else if(2000 <= a[i] && a[i] < 2400) sum[5]++;
			else if(2400 <= a[i] && a[i] < 2800) sum[6]++;
			else if(2800 <= a[i] && a[i] < 3200) sum[7]++;
			else if(3200 <= a[i]) sum[8]++;
		}
		int max = 0;
		int min = 0;
		int hatena = sum[8];
		for(int i = 0 ; i < 8 ; i++) {
			if(sum[i] >= 1) {
				max++;
				min++;
			}
		}
		if(min == 0) {
			System.out.println(1 + " " + hatena);
		} else {
			System.out.println(min + " " + (max + hatena));
		}
	}
}
