import java.util.Scanner;

public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int a[] = new int[n];
		int colors[] = new int[8];
		int free = 0;

		for (int i = 0; i < n; i++) {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		}

		int max = calcMax(free, colors);
		int min = 0;
		if (free == n) {
			min = 1;
		} else {
			min = calcMin(free, colors);
		}

		System.out.println(min + " " + max);

	}

	private static int calcMax(int count, int[] colors) {
		int max = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				max++;
			}
		}
		return max+count;
	}

	private static int calcMin(int count, int[] colors) {
		int min = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);
		for (int i = 0; i < count; i++) {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		}

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				min++;
			}
		}
		return min;
	}

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

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int a[] = new int[n];
		int colors[] = new int[8];
		int free = 0;

		for (int i = 0; i < n; i++) {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		}

		int max = calcMax(free, colors);
		int min = 0;
		if (free == n) {
			min = 1;
		} else {
			min = calcMin(free, colors);
		}

		System.out.println(min + " " + max);

	}

	private static int calcMax(int count, int[] colors) {
		int max = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				max++;
			}
		}
		return max+count;
	}

	private static int calcMin(int count, int[] colors) {
		int min = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);
		for (int i = 0; i < count; i++) {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		}

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				min++;
			}
		}
		return min;
	}

} Main @SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int a[] = new int[n];
		int colors[] = new int[8];
		int free = 0;

		for (int i = 0; i < n; i++) {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		}

		int max = calcMax(free, colors);
		int min = 0;
		if (free == n) {
			min = 1;
		} else {
			min = calcMin(free, colors);
		}

		System.out.println(min + " " + max);

	} main {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int a[] = new int[n];
		int colors[] = new int[8];
		int free = 0;

		for (int i = 0; i < n; i++) {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		}

		int max = calcMax(free, colors);
		int min = 0;
		if (free == n) {
			min = 1;
		} else {
			min = calcMin(free, colors);
		}

		System.out.println(min + " " + max);

	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int n = scanner.nextInt(); n scanner.nextInt() scanner.nextInt scanner int a[] = new int[n]; a new int[n] n int colors[] = new int[8]; colors new int[8] 8 int free = 0; free 0 for (int i = 0; i < n; i++) {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		} {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		} a[i] = scanner.nextInt() a[i] a i scanner.nextInt() scanner.nextInt scanner if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			} a[i] / 400 < 8 a[i] / 400 a[i] a i 400 8 {
				colors[a[i] / 400]++;
			} colors[a[i] / 400]++ colors[a[i] / 400] colors a[i] / 400 a[i] a i 400 {
				free++;
			} free++ free int max = calcMax(free, colors); max calcMax(free, colors) calcMax free colors int min = 0; min 0 if (free == n) {
			min = 1;
		} else {
			min = calcMin(free, colors);
		} free == n free n {
			min = 1;
		} min = 1 min 1 {
			min = calcMin(free, colors);
		} min = calcMin(free, colors) min calcMin(free, colors) calcMin free colors System.out.println(min + " " + max) System.out.println System.out System System.out min + " " + max min + " " + max min " " max String args[] args private static int calcMax(int count, int[] colors) {
		int max = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				max++;
			}
		}
		return max+count;
	} calcMax {
		int max = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				max++;
			}
		}
		return max+count;
	} int max = 0; max 0 int newColors[] = new int[8]; newColors new int[8] 8 System.arraycopy(colors, 0, newColors, 0, colors.length) System.arraycopy System colors 0 newColors 0 colors.length colors colors.length for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				max++;
			}
		} int i = 0; int i = 0; i 0 i < newColors.length i newColors.length newColors newColors.length i++ i++ i {
			if (newColors[i] > 0) {
				max++;
			}
		} {
			if (newColors[i] > 0) {
				max++;
			}
		} if (newColors[i] > 0) {
				max++;
			} newColors[i] > 0 newColors[i] newColors i 0 {
				max++;
			} max++ max return max+count; max+count max count int count count int[] colors colors private static int calcMin(int count, int[] colors) {
		int min = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);
		for (int i = 0; i < count; i++) {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		}

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				min++;
			}
		}
		return min;
	} calcMin {
		int min = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);
		for (int i = 0; i < count; i++) {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		}

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				min++;
			}
		}
		return min;
	} int min = 0; min 0 int newColors[] = new int[8]; newColors new int[8] 8 System.arraycopy(colors, 0, newColors, 0, colors.length) System.arraycopy System colors 0 newColors 0 colors.length colors colors.length for (int i = 0; i < count; i++) {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		} int i = 0; int i = 0; i 0 i < count i count i++ i++ i {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		} {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		} for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			} int j = 0; int j = 0; j 0 j < newColors.length j newColors.length newColors newColors.length j++ j++ j {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			} {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			} if (newColors[j] != 0) {
					newColors[j]++;
					break;
				} newColors[j] != 0 newColors[j] newColors j 0 {
					newColors[j]++;
					break;
				} newColors[j]++ newColors[j] newColors j break; for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				min++;
			}
		} int i = 0; int i = 0; i 0 i < newColors.length i newColors.length newColors newColors.length i++ i++ i {
			if (newColors[i] > 0) {
				min++;
			}
		} {
			if (newColors[i] > 0) {
				min++;
			}
		} if (newColors[i] > 0) {
				min++;
			} newColors[i] > 0 newColors[i] newColors i 0 {
				min++;
			} min++ min return min; min int count count int[] colors colors public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int a[] = new int[n];
		int colors[] = new int[8];
		int free = 0;

		for (int i = 0; i < n; i++) {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		}

		int max = calcMax(free, colors);
		int min = 0;
		if (free == n) {
			min = 1;
		} else {
			min = calcMin(free, colors);
		}

		System.out.println(min + " " + max);

	}

	private static int calcMax(int count, int[] colors) {
		int max = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				max++;
			}
		}
		return max+count;
	}

	private static int calcMin(int count, int[] colors) {
		int min = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);
		for (int i = 0; i < count; i++) {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		}

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				min++;
			}
		}
		return min;
	}

} public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int a[] = new int[n];
		int colors[] = new int[8];
		int free = 0;

		for (int i = 0; i < n; i++) {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		}

		int max = calcMax(free, colors);
		int min = 0;
		if (free == n) {
			min = 1;
		} else {
			min = calcMin(free, colors);
		}

		System.out.println(min + " " + max);

	}

	private static int calcMax(int count, int[] colors) {
		int max = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				max++;
			}
		}
		return max+count;
	}

	private static int calcMin(int count, int[] colors) {
		int min = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);
		for (int i = 0; i < count; i++) {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		}

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				min++;
			}
		}
		return min;
	}

} Main
import java.util.Scanner;

public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int a[] = new int[n];
		int colors[] = new int[8];
		int free = 0;

		for (int i = 0; i < n; i++) {
			a[i] = scanner.nextInt();
			if (a[i] / 400 < 8) {
				colors[a[i] / 400]++;
			} else {
				free++;
			}
		}

		int max = calcMax(free, colors);
		int min = 0;
		if (free == n) {
			min = 1;
		} else {
			min = calcMin(free, colors);
		}

		System.out.println(min + " " + max);

	}

	private static int calcMax(int count, int[] colors) {
		int max = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				max++;
			}
		}
		return max+count;
	}

	private static int calcMin(int count, int[] colors) {
		int min = 0;
		int newColors[] = new int[8];
		System.arraycopy(colors, 0, newColors, 0, colors.length);
		for (int i = 0; i < count; i++) {
			for (int j = 0; j < newColors.length; j++) {
				if (newColors[j] != 0) {
					newColors[j]++;
					break;
				}
			}
		}

		for (int i = 0; i < newColors.length; i++) {
			if (newColors[i] > 0) {
				min++;
			}
		}
		return min;
	}

}