import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.StringTokenizer;
 
public class Main {
	public static void main(String[] args) {
		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int[] colors = new int[8];
		int upper3200 = 0;
		int currColors = 0;
		
		for (int i = 0; i < n; i++) {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		}
		
		for (int i = 0; i < 8; i++) {
			if (colors[i] == 0) { currColors++; }
		}
		
		int resMin = Math.max(8 - currColors, 1);
		int resMax = 8 - currColors + upper3200;
		
		
		System.out.println(resMin + " " + resMax);
	}
  
    static class FastReader {
	    BufferedReader br;
	    StringTokenizer st;
	
	    public FastReader() {
	      br = new BufferedReader(new InputStreamReader(System.in));
	    }
	  
	    String next() { 
	      while (st == null || !st.hasMoreElements()) {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      }
	      return st.nextToken();
	    }
	
	    int nextInt() {
	      return Integer.parseInt(next());
	    }
	
	    long nextLong() {
	      return Long.parseLong(next());
	    }
	
	    double nextDouble() { 
	      return Double.parseDouble(next());
	    }
	
	    String nextLine() {
	      String str = "";
	        try{
	            str = br.readLine();
	        } catch (IOException e) {
	            e.printStackTrace();
	        }
	        return str;
	      }
	  }
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.Arrays; Arrays java.util import java.util.StringTokenizer; StringTokenizer java.util public class Main {
	public static void main(String[] args) {
		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int[] colors = new int[8];
		int upper3200 = 0;
		int currColors = 0;
		
		for (int i = 0; i < n; i++) {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		}
		
		for (int i = 0; i < 8; i++) {
			if (colors[i] == 0) { currColors++; }
		}
		
		int resMin = Math.max(8 - currColors, 1);
		int resMax = 8 - currColors + upper3200;
		
		
		System.out.println(resMin + " " + resMax);
	}
  
    static class FastReader {
	    BufferedReader br;
	    StringTokenizer st;
	
	    public FastReader() {
	      br = new BufferedReader(new InputStreamReader(System.in));
	    }
	  
	    String next() { 
	      while (st == null || !st.hasMoreElements()) {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      }
	      return st.nextToken();
	    }
	
	    int nextInt() {
	      return Integer.parseInt(next());
	    }
	
	    long nextLong() {
	      return Long.parseLong(next());
	    }
	
	    double nextDouble() { 
	      return Double.parseDouble(next());
	    }
	
	    String nextLine() {
	      String str = "";
	        try{
	            str = br.readLine();
	        } catch (IOException e) {
	            e.printStackTrace();
	        }
	        return str;
	      }
	  }
} Main public static void main(String[] args) {
		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int[] colors = new int[8];
		int upper3200 = 0;
		int currColors = 0;
		
		for (int i = 0; i < n; i++) {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		}
		
		for (int i = 0; i < 8; i++) {
			if (colors[i] == 0) { currColors++; }
		}
		
		int resMin = Math.max(8 - currColors, 1);
		int resMax = 8 - currColors + upper3200;
		
		
		System.out.println(resMin + " " + resMax);
	} main {
		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int[] colors = new int[8];
		int upper3200 = 0;
		int currColors = 0;
		
		for (int i = 0; i < n; i++) {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		}
		
		for (int i = 0; i < 8; i++) {
			if (colors[i] == 0) { currColors++; }
		}
		
		int resMin = Math.max(8 - currColors, 1);
		int resMax = 8 - currColors + upper3200;
		
		
		System.out.println(resMin + " " + resMax);
	} FastReader sc = new FastReader(); sc new FastReader() int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int[] colors = new int[8]; colors new int[8] 8 int upper3200 = 0; upper3200 0 int currColors = 0; currColors 0 for (int i = 0; i < n; i++) {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		} {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		} int rate = sc.nextInt(); rate sc.nextInt() sc.nextInt sc if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			} (rate >= 1) && (rate < 400) (rate >= 1) rate 1 (rate < 400) rate 400 {
				colors[0]++;
			} colors[0]++ colors[0] colors 0 if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			} (rate >= 400) && (rate < 800) (rate >= 400) rate 400 (rate < 800) rate 800 {
				colors[1]++;
			} colors[1]++ colors[1] colors 1 if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			} (rate >= 800) && (rate < 1200) (rate >= 800) rate 800 (rate < 1200) rate 1200 {
				colors[2]++;
			} colors[2]++ colors[2] colors 2 if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			} (rate >= 1200) && (rate < 1600) (rate >= 1200) rate 1200 (rate < 1600) rate 1600 {
				colors[3]++;
			} colors[3]++ colors[3] colors 3 if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			} (rate >= 1600) && (rate < 2000) (rate >= 1600) rate 1600 (rate < 2000) rate 2000 {
				colors[4]++;
			} colors[4]++ colors[4] colors 4 if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			} (rate >= 2000) && (rate < 2400) (rate >= 2000) rate 2000 (rate < 2400) rate 2400 {
				colors[5]++;
			} colors[5]++ colors[5] colors 5 if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			} (rate >= 2400) && (rate < 2800) (rate >= 2400) rate 2400 (rate < 2800) rate 2800 {
				colors[6]++;
			} colors[6]++ colors[6] colors 6 if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			} (rate >= 2800) && (rate < 3200) (rate >= 2800) rate 2800 (rate < 3200) rate 3200 {
				colors[7]++;
			} colors[7]++ colors[7] colors 7 {
				upper3200++;
			} upper3200++ upper3200 for (int i = 0; i < 8; i++) {
			if (colors[i] == 0) { currColors++; }
		} int i = 0; int i = 0; i 0 i < 8 i 8 i++ i++ i {
			if (colors[i] == 0) { currColors++; }
		} {
			if (colors[i] == 0) { currColors++; }
		} if (colors[i] == 0) { currColors++; } colors[i] == 0 colors[i] colors i 0 { currColors++; } currColors++ currColors int resMin = Math.max(8 - currColors, 1); resMin Math.max(8 - currColors, 1) Math.max Math 8 - currColors 8 currColors 1 int resMax = 8 - currColors + upper3200; resMax 8 - currColors + upper3200 8 - currColors 8 currColors upper3200 System.out.println(resMin + " " + resMax) System.out.println System.out System System.out resMin + " " + resMax resMin + " " + resMax resMin " " resMax String[] args args static class FastReader {
	    BufferedReader br;
	    StringTokenizer st;
	
	    public FastReader() {
	      br = new BufferedReader(new InputStreamReader(System.in));
	    }
	  
	    String next() { 
	      while (st == null || !st.hasMoreElements()) {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      }
	      return st.nextToken();
	    }
	
	    int nextInt() {
	      return Integer.parseInt(next());
	    }
	
	    long nextLong() {
	      return Long.parseLong(next());
	    }
	
	    double nextDouble() { 
	      return Double.parseDouble(next());
	    }
	
	    String nextLine() {
	      String str = "";
	        try{
	            str = br.readLine();
	        } catch (IOException e) {
	            e.printStackTrace();
	        }
	        return str;
	      }
	  } FastReader BufferedReader br; br StringTokenizer st; st public FastReader() {
	      br = new BufferedReader(new InputStreamReader(System.in));
	    } FastReader {
	      br = new BufferedReader(new InputStreamReader(System.in));
	    } br = new BufferedReader(new InputStreamReader(System.in)) br new BufferedReader(new InputStreamReader(System.in)) String next() { 
	      while (st == null || !st.hasMoreElements()) {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      }
	      return st.nextToken();
	    } next { 
	      while (st == null || !st.hasMoreElements()) {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      }
	      return st.nextToken();
	    } while (st == null || !st.hasMoreElements()) {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      } st == null || !st.hasMoreElements() st == null st null !st.hasMoreElements() st.hasMoreElements() st.hasMoreElements st {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      } try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        } catch (IOException  e) {
	          e.printStackTrace();
	        } IOException  e {
	          e.printStackTrace();
	        } e.printStackTrace() e.printStackTrace e {
	          st = new StringTokenizer(br.readLine());
	        } st = new StringTokenizer(br.readLine()) st new StringTokenizer(br.readLine()) return st.nextToken(); st.nextToken() st.nextToken st int nextInt() {
	      return Integer.parseInt(next());
	    } nextInt {
	      return Integer.parseInt(next());
	    } return Integer.parseInt(next()); Integer.parseInt(next()) Integer.parseInt Integer next() next long nextLong() {
	      return Long.parseLong(next());
	    } nextLong {
	      return Long.parseLong(next());
	    } return Long.parseLong(next()); Long.parseLong(next()) Long.parseLong Long next() next double nextDouble() { 
	      return Double.parseDouble(next());
	    } nextDouble { 
	      return Double.parseDouble(next());
	    } return Double.parseDouble(next()); Double.parseDouble(next()) Double.parseDouble Double next() next String nextLine() {
	      String str = "";
	        try{
	            str = br.readLine();
	        } catch (IOException e) {
	            e.printStackTrace();
	        }
	        return str;
	      } nextLine {
	      String str = "";
	        try{
	            str = br.readLine();
	        } catch (IOException e) {
	            e.printStackTrace();
	        }
	        return str;
	      } String str = ""; str "" try{
	            str = br.readLine();
	        } catch (IOException e) {
	            e.printStackTrace();
	        } catch (IOException e) {
	            e.printStackTrace();
	        } IOException e {
	            e.printStackTrace();
	        } e.printStackTrace() e.printStackTrace e {
	            str = br.readLine();
	        } str = br.readLine() str br.readLine() br.readLine br return str; str public class Main {
	public static void main(String[] args) {
		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int[] colors = new int[8];
		int upper3200 = 0;
		int currColors = 0;
		
		for (int i = 0; i < n; i++) {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		}
		
		for (int i = 0; i < 8; i++) {
			if (colors[i] == 0) { currColors++; }
		}
		
		int resMin = Math.max(8 - currColors, 1);
		int resMax = 8 - currColors + upper3200;
		
		
		System.out.println(resMin + " " + resMax);
	}
  
    static class FastReader {
	    BufferedReader br;
	    StringTokenizer st;
	
	    public FastReader() {
	      br = new BufferedReader(new InputStreamReader(System.in));
	    }
	  
	    String next() { 
	      while (st == null || !st.hasMoreElements()) {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      }
	      return st.nextToken();
	    }
	
	    int nextInt() {
	      return Integer.parseInt(next());
	    }
	
	    long nextLong() {
	      return Long.parseLong(next());
	    }
	
	    double nextDouble() { 
	      return Double.parseDouble(next());
	    }
	
	    String nextLine() {
	      String str = "";
	        try{
	            str = br.readLine();
	        } catch (IOException e) {
	            e.printStackTrace();
	        }
	        return str;
	      }
	  }
} public class Main {
	public static void main(String[] args) {
		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int[] colors = new int[8];
		int upper3200 = 0;
		int currColors = 0;
		
		for (int i = 0; i < n; i++) {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		}
		
		for (int i = 0; i < 8; i++) {
			if (colors[i] == 0) { currColors++; }
		}
		
		int resMin = Math.max(8 - currColors, 1);
		int resMax = 8 - currColors + upper3200;
		
		
		System.out.println(resMin + " " + resMax);
	}
  
    static class FastReader {
	    BufferedReader br;
	    StringTokenizer st;
	
	    public FastReader() {
	      br = new BufferedReader(new InputStreamReader(System.in));
	    }
	  
	    String next() { 
	      while (st == null || !st.hasMoreElements()) {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      }
	      return st.nextToken();
	    }
	
	    int nextInt() {
	      return Integer.parseInt(next());
	    }
	
	    long nextLong() {
	      return Long.parseLong(next());
	    }
	
	    double nextDouble() { 
	      return Double.parseDouble(next());
	    }
	
	    String nextLine() {
	      String str = "";
	        try{
	            str = br.readLine();
	        } catch (IOException e) {
	            e.printStackTrace();
	        }
	        return str;
	      }
	  }
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.StringTokenizer;
 
public class Main {
	public static void main(String[] args) {
		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int[] colors = new int[8];
		int upper3200 = 0;
		int currColors = 0;
		
		for (int i = 0; i < n; i++) {
			int rate = sc.nextInt();
			
			if ((rate >= 1) && (rate < 400)) {
				colors[0]++;
			} else if ((rate >= 400) && (rate < 800)) {
				colors[1]++;
			} else if ((rate >= 800) && (rate < 1200)) {
				colors[2]++;
			} else if ((rate >= 1200) && (rate < 1600)) {
				colors[3]++;
			} else if ((rate >= 1600) && (rate < 2000)) {
				colors[4]++;
			} else if ((rate >= 2000) && (rate < 2400)) {
				colors[5]++;
			} else if ((rate >= 2400) && (rate < 2800)) {
				colors[6]++;
			} else if ((rate >= 2800) && (rate < 3200)) {
				colors[7]++;
			} else {
				upper3200++;
			}
		}
		
		for (int i = 0; i < 8; i++) {
			if (colors[i] == 0) { currColors++; }
		}
		
		int resMin = Math.max(8 - currColors, 1);
		int resMax = 8 - currColors + upper3200;
		
		
		System.out.println(resMin + " " + resMax);
	}
  
    static class FastReader {
	    BufferedReader br;
	    StringTokenizer st;
	
	    public FastReader() {
	      br = new BufferedReader(new InputStreamReader(System.in));
	    }
	  
	    String next() { 
	      while (st == null || !st.hasMoreElements()) {
	        try {
	          st = new StringTokenizer(br.readLine());
	        } catch (IOException  e) {
	          e.printStackTrace();
	        }
	      }
	      return st.nextToken();
	    }
	
	    int nextInt() {
	      return Integer.parseInt(next());
	    }
	
	    long nextLong() {
	      return Long.parseLong(next());
	    }
	
	    double nextDouble() { 
	      return Double.parseDouble(next());
	    }
	
	    String nextLine() {
	      String str = "";
	        try{
	            str = br.readLine();
	        } catch (IOException e) {
	            e.printStackTrace();
	        }
	        return str;
	      }
	  }
}