import java.util.*; import java.io.*; import java.math.*;
public class Main{
	//Don't have to see. start------------------------------------------
	static class InputIterator{
		ArrayList<String> inputLine = new ArrayList<String>(1024);
		int index = 0; int max; String read;
		InputIterator(){
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
			try{
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			}catch(IOException e){}
			max = inputLine.size();
		}
		boolean hasNext(){return (index < max);}
		String next(){
			if(hasNext()){
				return inputLine.get(index++);
			}else{
				throw new IndexOutOfBoundsException("There is no more input");
			}
		}
	}
	static HashMap<Integer, String> CONVSTR = new HashMap<Integer, String>();
	static InputIterator ii = new InputIterator();//This class cannot be used in reactive problem.
	static PrintWriter out = new PrintWriter(System.out);
	static void flush(){out.flush();}
	static void myout(Object t){out.println(t);}
	static void myerr(Object t){System.err.print("debug:");System.err.println(t);}
	static String next(){return ii.next();}
	static boolean hasNext(){return ii.hasNext();}
	static int nextInt(){return Integer.parseInt(next());}
	static long nextLong(){return Long.parseLong(next());}
	static double nextDouble(){return Double.parseDouble(next());}
	static ArrayList<String> nextStrArray(){return myconv(next(), 8);}
	static ArrayList<String> nextCharArray(){return myconv(next(), 0);}
	static ArrayList<Integer> nextIntArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Integer> ret = new ArrayList<Integer>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Integer.parseInt(input.get(i)));
		}
		return ret;
	}
	static ArrayList<Long> nextLongArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Long> ret = new ArrayList<Long>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Long.parseLong(input.get(i)));
		}
		return ret;
	}
	static String myconv(Object list, int no){//only join
		String joinString = CONVSTR.get(no);
		if(list instanceof String[]){
			return String.join(joinString, (String[])list);
		}else if(list instanceof ArrayList){
			return String.join(joinString, (ArrayList)list);
		}else{
			throw new ClassCastException("Don't join");
		}
	}
	static ArrayList<String> myconv(String str, int no){//only split
		String splitString = CONVSTR.get(no);
		return new ArrayList<String>(Arrays.asList(str.split(splitString)));
	}
	public static void main(String[] args){
		CONVSTR.put(8, " "); CONVSTR.put(9, "\n"); CONVSTR.put(0, "");
		solve();flush();
	}
	//Don't have to see. end------------------------------------------
	static void solve(){//Here is the main function
  int N = nextInt();
  ArrayList<Integer> tmp = nextIntArray();
  int[] list = new int[N];
  for(int i = 0; i < N; i++){
  	list[i] = tmp.get(i);
  }
  HashSet<String> set = new HashSet<String>();
  int all = 0;
  int notall = 0;
  for(int i = 0; i < N; i++){
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  }
  myerr(set);
  int min = notall;
  int max = notall + all;
  if(min == 0 && all >= 1){
     min = 1;
  }
  myout(min + " " + max);
	}
	//Method addition frame start



	//Method addition frame end
} import java.util.*; util.* java import java.io.*; io.* java import java.math.*; math.* java public class Main{
	//Don't have to see. start------------------------------------------
	static class InputIterator{
		ArrayList<String> inputLine = new ArrayList<String>(1024);
		int index = 0; int max; String read;
		InputIterator(){
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
			try{
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			}catch(IOException e){}
			max = inputLine.size();
		}
		boolean hasNext(){return (index < max);}
		String next(){
			if(hasNext()){
				return inputLine.get(index++);
			}else{
				throw new IndexOutOfBoundsException("There is no more input");
			}
		}
	}
	static HashMap<Integer, String> CONVSTR = new HashMap<Integer, String>();
	static InputIterator ii = new InputIterator();//This class cannot be used in reactive problem.
	static PrintWriter out = new PrintWriter(System.out);
	static void flush(){out.flush();}
	static void myout(Object t){out.println(t);}
	static void myerr(Object t){System.err.print("debug:");System.err.println(t);}
	static String next(){return ii.next();}
	static boolean hasNext(){return ii.hasNext();}
	static int nextInt(){return Integer.parseInt(next());}
	static long nextLong(){return Long.parseLong(next());}
	static double nextDouble(){return Double.parseDouble(next());}
	static ArrayList<String> nextStrArray(){return myconv(next(), 8);}
	static ArrayList<String> nextCharArray(){return myconv(next(), 0);}
	static ArrayList<Integer> nextIntArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Integer> ret = new ArrayList<Integer>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Integer.parseInt(input.get(i)));
		}
		return ret;
	}
	static ArrayList<Long> nextLongArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Long> ret = new ArrayList<Long>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Long.parseLong(input.get(i)));
		}
		return ret;
	}
	static String myconv(Object list, int no){//only join
		String joinString = CONVSTR.get(no);
		if(list instanceof String[]){
			return String.join(joinString, (String[])list);
		}else if(list instanceof ArrayList){
			return String.join(joinString, (ArrayList)list);
		}else{
			throw new ClassCastException("Don't join");
		}
	}
	static ArrayList<String> myconv(String str, int no){//only split
		String splitString = CONVSTR.get(no);
		return new ArrayList<String>(Arrays.asList(str.split(splitString)));
	}
	public static void main(String[] args){
		CONVSTR.put(8, " "); CONVSTR.put(9, "\n"); CONVSTR.put(0, "");
		solve();flush();
	}
	//Don't have to see. end------------------------------------------
	static void solve(){//Here is the main function
  int N = nextInt();
  ArrayList<Integer> tmp = nextIntArray();
  int[] list = new int[N];
  for(int i = 0; i < N; i++){
  	list[i] = tmp.get(i);
  }
  HashSet<String> set = new HashSet<String>();
  int all = 0;
  int notall = 0;
  for(int i = 0; i < N; i++){
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  }
  myerr(set);
  int min = notall;
  int max = notall + all;
  if(min == 0 && all >= 1){
     min = 1;
  }
  myout(min + " " + max);
	}
	//Method addition frame start



	//Method addition frame end
} Main static HashMap<Integer, String> CONVSTR = new HashMap<Integer, String>(); CONVSTR new HashMap<Integer, String>() static InputIterator ii = new InputIterator();//This class cannot be used in reactive problem. ii new InputIterator() static PrintWriter out = new PrintWriter(System.out); out new PrintWriter(System.out) static void flush(){out.flush();} flush {out.flush();} out.flush() out.flush out static void myout(Object t){out.println(t);} myout {out.println(t);} out.println(t) out.println out t Object t t static void myerr(Object t){System.err.print("debug:");System.err.println(t);} myerr {System.err.print("debug:");System.err.println(t);} System.err.print("debug:") System.err.print System.err System System.err "debug:" System.err.println(t) System.err.println System.err System System.err t Object t t static String next(){return ii.next();} next {return ii.next();} return ii.next(); ii.next() ii.next ii static boolean hasNext(){return ii.hasNext();} hasNext {return ii.hasNext();} return ii.hasNext(); ii.hasNext() ii.hasNext ii static int nextInt(){return Integer.parseInt(next());} nextInt {return Integer.parseInt(next());} return Integer.parseInt(next()); Integer.parseInt(next()) Integer.parseInt Integer next() next static long nextLong(){return Long.parseLong(next());} nextLong {return Long.parseLong(next());} return Long.parseLong(next()); Long.parseLong(next()) Long.parseLong Long next() next static double nextDouble(){return Double.parseDouble(next());} nextDouble {return Double.parseDouble(next());} return Double.parseDouble(next()); Double.parseDouble(next()) Double.parseDouble Double next() next static ArrayList<String> nextStrArray(){return myconv(next(), 8);} nextStrArray {return myconv(next(), 8);} return myconv(next(), 8); myconv(next(), 8) myconv next() next 8 static ArrayList<String> nextCharArray(){return myconv(next(), 0);} nextCharArray {return myconv(next(), 0);} return myconv(next(), 0); myconv(next(), 0) myconv next() next 0 static ArrayList<Integer> nextIntArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Integer> ret = new ArrayList<Integer>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Integer.parseInt(input.get(i)));
		}
		return ret;
	} nextIntArray {
		ArrayList<String> input = nextStrArray(); ArrayList<Integer> ret = new ArrayList<Integer>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Integer.parseInt(input.get(i)));
		}
		return ret;
	} ArrayList<String> input = nextStrArray(); input nextStrArray() nextStrArray ArrayList<Integer> ret = new ArrayList<Integer>(input.size()); ret new ArrayList<Integer>(input.size()) for(int i = 0; i < input.size(); i++){
			ret.add(Integer.parseInt(input.get(i)));
		} int i = 0; int i = 0; i 0 i < input.size() i input.size() input.size input i++ i++ i {
			ret.add(Integer.parseInt(input.get(i)));
		} {
			ret.add(Integer.parseInt(input.get(i)));
		} ret.add(Integer.parseInt(input.get(i))) ret.add ret Integer.parseInt(input.get(i)) Integer.parseInt Integer input.get(i) input.get input i return ret; ret static ArrayList<Long> nextLongArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Long> ret = new ArrayList<Long>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Long.parseLong(input.get(i)));
		}
		return ret;
	} nextLongArray {
		ArrayList<String> input = nextStrArray(); ArrayList<Long> ret = new ArrayList<Long>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Long.parseLong(input.get(i)));
		}
		return ret;
	} ArrayList<String> input = nextStrArray(); input nextStrArray() nextStrArray ArrayList<Long> ret = new ArrayList<Long>(input.size()); ret new ArrayList<Long>(input.size()) for(int i = 0; i < input.size(); i++){
			ret.add(Long.parseLong(input.get(i)));
		} int i = 0; int i = 0; i 0 i < input.size() i input.size() input.size input i++ i++ i {
			ret.add(Long.parseLong(input.get(i)));
		} {
			ret.add(Long.parseLong(input.get(i)));
		} ret.add(Long.parseLong(input.get(i))) ret.add ret Long.parseLong(input.get(i)) Long.parseLong Long input.get(i) input.get input i return ret; ret static String myconv(Object list, int no){//only join
		String joinString = CONVSTR.get(no);
		if(list instanceof String[]){
			return String.join(joinString, (String[])list);
		}else if(list instanceof ArrayList){
			return String.join(joinString, (ArrayList)list);
		}else{
			throw new ClassCastException("Don't join");
		}
	} myconv {//only join
		String joinString = CONVSTR.get(no);
		if(list instanceof String[]){
			return String.join(joinString, (String[])list);
		}else if(list instanceof ArrayList){
			return String.join(joinString, (ArrayList)list);
		}else{
			throw new ClassCastException("Don't join");
		}
	} String joinString = CONVSTR.get(no); joinString CONVSTR.get(no) CONVSTR.get CONVSTR no if(list instanceof String[]){
			return String.join(joinString, (String[])list);
		}else if(list instanceof ArrayList){
			return String.join(joinString, (ArrayList)list);
		}else{
			throw new ClassCastException("Don't join");
		} list instanceof String[] list String[] {
			return String.join(joinString, (String[])list);
		} return String.join(joinString, (String[])list); String.join(joinString, (String[])list) String.join String joinString (String[])list if(list instanceof ArrayList){
			return String.join(joinString, (ArrayList)list);
		}else{
			throw new ClassCastException("Don't join");
		} list instanceof ArrayList list ArrayList {
			return String.join(joinString, (ArrayList)list);
		} return String.join(joinString, (ArrayList)list); String.join(joinString, (ArrayList)list) String.join String joinString (ArrayList)list {
			throw new ClassCastException("Don't join");
		} throw new ClassCastException("Don't join"); new ClassCastException("Don't join") Object list list int no no static ArrayList<String> myconv(String str, int no){//only split
		String splitString = CONVSTR.get(no);
		return new ArrayList<String>(Arrays.asList(str.split(splitString)));
	} myconv {//only split
		String splitString = CONVSTR.get(no);
		return new ArrayList<String>(Arrays.asList(str.split(splitString)));
	} String splitString = CONVSTR.get(no); splitString CONVSTR.get(no) CONVSTR.get CONVSTR no return new ArrayList<String>(Arrays.asList(str.split(splitString))); new ArrayList<String>(Arrays.asList(str.split(splitString))) String str str int no no public static void main(String[] args){
		CONVSTR.put(8, " "); CONVSTR.put(9, "\n"); CONVSTR.put(0, "");
		solve();flush();
	} main {
		CONVSTR.put(8, " "); CONVSTR.put(9, "\n"); CONVSTR.put(0, "");
		solve();flush();
	} CONVSTR.put(8, " ") CONVSTR.put CONVSTR 8 " " CONVSTR.put(9, "\n") CONVSTR.put CONVSTR 9 "\n" CONVSTR.put(0, "") CONVSTR.put CONVSTR 0 "" solve() solve flush() flush String[] args args //Don't have to see. end------------------------------------------
	static void solve(){//Here is the main function
  int N = nextInt();
  ArrayList<Integer> tmp = nextIntArray();
  int[] list = new int[N];
  for(int i = 0; i < N; i++){
  	list[i] = tmp.get(i);
  }
  HashSet<String> set = new HashSet<String>();
  int all = 0;
  int notall = 0;
  for(int i = 0; i < N; i++){
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  }
  myerr(set);
  int min = notall;
  int max = notall + all;
  if(min == 0 && all >= 1){
     min = 1;
  }
  myout(min + " " + max);
	} solve {//Here is the main function
  int N = nextInt();
  ArrayList<Integer> tmp = nextIntArray();
  int[] list = new int[N];
  for(int i = 0; i < N; i++){
  	list[i] = tmp.get(i);
  }
  HashSet<String> set = new HashSet<String>();
  int all = 0;
  int notall = 0;
  for(int i = 0; i < N; i++){
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  }
  myerr(set);
  int min = notall;
  int max = notall + all;
  if(min == 0 && all >= 1){
     min = 1;
  }
  myout(min + " " + max);
	} int N = nextInt(); N nextInt() nextInt ArrayList<Integer> tmp = nextIntArray(); tmp nextIntArray() nextIntArray int[] list = new int[N]; list new int[N] N for(int i = 0; i < N; i++){
  	list[i] = tmp.get(i);
  } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
  	list[i] = tmp.get(i);
  } {
  	list[i] = tmp.get(i);
  } list[i] = tmp.get(i) list[i] list i tmp.get(i) tmp.get tmp i HashSet<String> set = new HashSet<String>(); set new HashSet<String>() int all = 0; all 0 int notall = 0; notall 0 for(int i = 0; i < N; i++){
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  } {
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  } if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    } list[i] >= 1 && list[i] <= 399 && !set.contains("gray") list[i] >= 1 && list[i] <= 399 && !set.contains("gray") list[i] >= 1 list[i] list i 1 list[i] <= 399 list[i] list i 399 !set.contains("gray") set.contains("gray") set.contains set "gray" {
       set.add("gray");
      notall++;
    } set.add("gray") set.add set "gray" notall++ notall if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    } list[i] >= 400 && list[i] <= 799 && !set.contains("brown") list[i] >= 400 && list[i] <= 799 && !set.contains("brown") list[i] >= 400 list[i] list i 400 list[i] <= 799 list[i] list i 799 !set.contains("brown") set.contains("brown") set.contains set "brown" {
       set.add("brown");
      notall++;
    } set.add("brown") set.add set "brown" notall++ notall if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    } list[i] >= 800 && list[i] <= 1199 && !set.contains("green") list[i] >= 800 && list[i] <= 1199 && !set.contains("green") list[i] >= 800 list[i] list i 800 list[i] <= 1199 list[i] list i 1199 !set.contains("green") set.contains("green") set.contains set "green" {
       set.add("green");
      notall++;
    } set.add("green") set.add set "green" notall++ notall if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    } list[i] >= 1200 && list[i] <= 1599 && !set.contains("water") list[i] >= 1200 && list[i] <= 1599 && !set.contains("water") list[i] >= 1200 list[i] list i 1200 list[i] <= 1599 list[i] list i 1599 !set.contains("water") set.contains("water") set.contains set "water" {
       set.add("water");
      notall++;
    } set.add("water") set.add set "water" notall++ notall if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    } list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue") list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue") list[i] >= 1600 list[i] list i 1600 list[i] <= 1999 list[i] list i 1999 !set.contains("blue") set.contains("blue") set.contains set "blue" {
       set.add("blue");
      notall++;
    } set.add("blue") set.add set "blue" notall++ notall if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    } list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow") list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow") list[i] >= 2000 list[i] list i 2000 list[i] <= 2399 list[i] list i 2399 !set.contains("yellow") set.contains("yellow") set.contains set "yellow" {
       set.add("yellow");
      notall++;
    } set.add("yellow") set.add set "yellow" notall++ notall if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    } list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange") list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange") list[i] >= 2400 list[i] list i 2400 list[i] <= 2799 list[i] list i 2799 !set.contains("orange") set.contains("orange") set.contains set "orange" {
       set.add("orange");
      notall++;
    } set.add("orange") set.add set "orange" notall++ notall if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    } list[i] >= 2800 && list[i] <= 3199 && !set.contains("red") list[i] >= 2800 && list[i] <= 3199 && !set.contains("red") list[i] >= 2800 list[i] list i 2800 list[i] <= 3199 list[i] list i 3199 !set.contains("red") set.contains("red") set.contains set "red" {
       set.add("red");
      notall++;
    } set.add("red") set.add set "red" notall++ notall if(list[i] >= 3200){
       all++;
    } list[i] >= 3200 list[i] list i 3200 {
       all++;
    } all++ all myerr(set) myerr set int min = notall; min notall int max = notall + all; max notall + all notall all if(min == 0 && all >= 1){
     min = 1;
  } min == 0 && all >= 1 min == 0 min 0 all >= 1 all 1 {
     min = 1;
  } min = 1 min 1 myout(min + " " + max) myout min + " " + max min + " " + max min " " max static class InputIterator{
		ArrayList<String> inputLine = new ArrayList<String>(1024);
		int index = 0; int max; String read;
		InputIterator(){
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
			try{
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			}catch(IOException e){}
			max = inputLine.size();
		}
		boolean hasNext(){return (index < max);}
		String next(){
			if(hasNext()){
				return inputLine.get(index++);
			}else{
				throw new IndexOutOfBoundsException("There is no more input");
			}
		}
	} InputIterator ArrayList<String> inputLine = new ArrayList<String>(1024); inputLine new ArrayList<String>(1024) int index = 0; index 0 int max; max String read; read InputIterator(){
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
			try{
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			}catch(IOException e){}
			max = inputLine.size();
		} InputIterator {
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
			try{
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			}catch(IOException e){}
			max = inputLine.size();
		} BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) try{
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			}catch(IOException e){} catch(IOException e){} IOException e {} {
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			} while((read = br.readLine()) != null){
					inputLine.add(read);
				} (read = br.readLine()) != null (read = br.readLine()) read br.readLine() br.readLine br null {
					inputLine.add(read);
				} inputLine.add(read) inputLine.add inputLine read max = inputLine.size() max inputLine.size() inputLine.size inputLine boolean hasNext(){return (index < max);} hasNext {return (index < max);} return (index < max); (index < max) index max String next(){
			if(hasNext()){
				return inputLine.get(index++);
			}else{
				throw new IndexOutOfBoundsException("There is no more input");
			}
		} next {
			if(hasNext()){
				return inputLine.get(index++);
			}else{
				throw new IndexOutOfBoundsException("There is no more input");
			}
		} if(hasNext()){
				return inputLine.get(index++);
			}else{
				throw new IndexOutOfBoundsException("There is no more input");
			} hasNext() hasNext {
				return inputLine.get(index++);
			} return inputLine.get(index++); inputLine.get(index++) inputLine.get inputLine index++ index {
				throw new IndexOutOfBoundsException("There is no more input");
			} throw new IndexOutOfBoundsException("There is no more input"); new IndexOutOfBoundsException("There is no more input") public class Main{
	//Don't have to see. start------------------------------------------
	static class InputIterator{
		ArrayList<String> inputLine = new ArrayList<String>(1024);
		int index = 0; int max; String read;
		InputIterator(){
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
			try{
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			}catch(IOException e){}
			max = inputLine.size();
		}
		boolean hasNext(){return (index < max);}
		String next(){
			if(hasNext()){
				return inputLine.get(index++);
			}else{
				throw new IndexOutOfBoundsException("There is no more input");
			}
		}
	}
	static HashMap<Integer, String> CONVSTR = new HashMap<Integer, String>();
	static InputIterator ii = new InputIterator();//This class cannot be used in reactive problem.
	static PrintWriter out = new PrintWriter(System.out);
	static void flush(){out.flush();}
	static void myout(Object t){out.println(t);}
	static void myerr(Object t){System.err.print("debug:");System.err.println(t);}
	static String next(){return ii.next();}
	static boolean hasNext(){return ii.hasNext();}
	static int nextInt(){return Integer.parseInt(next());}
	static long nextLong(){return Long.parseLong(next());}
	static double nextDouble(){return Double.parseDouble(next());}
	static ArrayList<String> nextStrArray(){return myconv(next(), 8);}
	static ArrayList<String> nextCharArray(){return myconv(next(), 0);}
	static ArrayList<Integer> nextIntArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Integer> ret = new ArrayList<Integer>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Integer.parseInt(input.get(i)));
		}
		return ret;
	}
	static ArrayList<Long> nextLongArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Long> ret = new ArrayList<Long>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Long.parseLong(input.get(i)));
		}
		return ret;
	}
	static String myconv(Object list, int no){//only join
		String joinString = CONVSTR.get(no);
		if(list instanceof String[]){
			return String.join(joinString, (String[])list);
		}else if(list instanceof ArrayList){
			return String.join(joinString, (ArrayList)list);
		}else{
			throw new ClassCastException("Don't join");
		}
	}
	static ArrayList<String> myconv(String str, int no){//only split
		String splitString = CONVSTR.get(no);
		return new ArrayList<String>(Arrays.asList(str.split(splitString)));
	}
	public static void main(String[] args){
		CONVSTR.put(8, " "); CONVSTR.put(9, "\n"); CONVSTR.put(0, "");
		solve();flush();
	}
	//Don't have to see. end------------------------------------------
	static void solve(){//Here is the main function
  int N = nextInt();
  ArrayList<Integer> tmp = nextIntArray();
  int[] list = new int[N];
  for(int i = 0; i < N; i++){
  	list[i] = tmp.get(i);
  }
  HashSet<String> set = new HashSet<String>();
  int all = 0;
  int notall = 0;
  for(int i = 0; i < N; i++){
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  }
  myerr(set);
  int min = notall;
  int max = notall + all;
  if(min == 0 && all >= 1){
     min = 1;
  }
  myout(min + " " + max);
	}
	//Method addition frame start



	//Method addition frame end
} public class Main{
	//Don't have to see. start------------------------------------------
	static class InputIterator{
		ArrayList<String> inputLine = new ArrayList<String>(1024);
		int index = 0; int max; String read;
		InputIterator(){
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
			try{
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			}catch(IOException e){}
			max = inputLine.size();
		}
		boolean hasNext(){return (index < max);}
		String next(){
			if(hasNext()){
				return inputLine.get(index++);
			}else{
				throw new IndexOutOfBoundsException("There is no more input");
			}
		}
	}
	static HashMap<Integer, String> CONVSTR = new HashMap<Integer, String>();
	static InputIterator ii = new InputIterator();//This class cannot be used in reactive problem.
	static PrintWriter out = new PrintWriter(System.out);
	static void flush(){out.flush();}
	static void myout(Object t){out.println(t);}
	static void myerr(Object t){System.err.print("debug:");System.err.println(t);}
	static String next(){return ii.next();}
	static boolean hasNext(){return ii.hasNext();}
	static int nextInt(){return Integer.parseInt(next());}
	static long nextLong(){return Long.parseLong(next());}
	static double nextDouble(){return Double.parseDouble(next());}
	static ArrayList<String> nextStrArray(){return myconv(next(), 8);}
	static ArrayList<String> nextCharArray(){return myconv(next(), 0);}
	static ArrayList<Integer> nextIntArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Integer> ret = new ArrayList<Integer>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Integer.parseInt(input.get(i)));
		}
		return ret;
	}
	static ArrayList<Long> nextLongArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Long> ret = new ArrayList<Long>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Long.parseLong(input.get(i)));
		}
		return ret;
	}
	static String myconv(Object list, int no){//only join
		String joinString = CONVSTR.get(no);
		if(list instanceof String[]){
			return String.join(joinString, (String[])list);
		}else if(list instanceof ArrayList){
			return String.join(joinString, (ArrayList)list);
		}else{
			throw new ClassCastException("Don't join");
		}
	}
	static ArrayList<String> myconv(String str, int no){//only split
		String splitString = CONVSTR.get(no);
		return new ArrayList<String>(Arrays.asList(str.split(splitString)));
	}
	public static void main(String[] args){
		CONVSTR.put(8, " "); CONVSTR.put(9, "\n"); CONVSTR.put(0, "");
		solve();flush();
	}
	//Don't have to see. end------------------------------------------
	static void solve(){//Here is the main function
  int N = nextInt();
  ArrayList<Integer> tmp = nextIntArray();
  int[] list = new int[N];
  for(int i = 0; i < N; i++){
  	list[i] = tmp.get(i);
  }
  HashSet<String> set = new HashSet<String>();
  int all = 0;
  int notall = 0;
  for(int i = 0; i < N; i++){
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  }
  myerr(set);
  int min = notall;
  int max = notall + all;
  if(min == 0 && all >= 1){
     min = 1;
  }
  myout(min + " " + max);
	}
	//Method addition frame start



	//Method addition frame end
} Main
import java.util.*; import java.io.*; import java.math.*;
public class Main{
	//Don't have to see. start------------------------------------------
	static class InputIterator{
		ArrayList<String> inputLine = new ArrayList<String>(1024);
		int index = 0; int max; String read;
		InputIterator(){
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
			try{
				while((read = br.readLine()) != null){
					inputLine.add(read);
				}
			}catch(IOException e){}
			max = inputLine.size();
		}
		boolean hasNext(){return (index < max);}
		String next(){
			if(hasNext()){
				return inputLine.get(index++);
			}else{
				throw new IndexOutOfBoundsException("There is no more input");
			}
		}
	}
	static HashMap<Integer, String> CONVSTR = new HashMap<Integer, String>();
	static InputIterator ii = new InputIterator();//This class cannot be used in reactive problem.
	static PrintWriter out = new PrintWriter(System.out);
	static void flush(){out.flush();}
	static void myout(Object t){out.println(t);}
	static void myerr(Object t){System.err.print("debug:");System.err.println(t);}
	static String next(){return ii.next();}
	static boolean hasNext(){return ii.hasNext();}
	static int nextInt(){return Integer.parseInt(next());}
	static long nextLong(){return Long.parseLong(next());}
	static double nextDouble(){return Double.parseDouble(next());}
	static ArrayList<String> nextStrArray(){return myconv(next(), 8);}
	static ArrayList<String> nextCharArray(){return myconv(next(), 0);}
	static ArrayList<Integer> nextIntArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Integer> ret = new ArrayList<Integer>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Integer.parseInt(input.get(i)));
		}
		return ret;
	}
	static ArrayList<Long> nextLongArray(){
		ArrayList<String> input = nextStrArray(); ArrayList<Long> ret = new ArrayList<Long>(input.size());
		for(int i = 0; i < input.size(); i++){
			ret.add(Long.parseLong(input.get(i)));
		}
		return ret;
	}
	static String myconv(Object list, int no){//only join
		String joinString = CONVSTR.get(no);
		if(list instanceof String[]){
			return String.join(joinString, (String[])list);
		}else if(list instanceof ArrayList){
			return String.join(joinString, (ArrayList)list);
		}else{
			throw new ClassCastException("Don't join");
		}
	}
	static ArrayList<String> myconv(String str, int no){//only split
		String splitString = CONVSTR.get(no);
		return new ArrayList<String>(Arrays.asList(str.split(splitString)));
	}
	public static void main(String[] args){
		CONVSTR.put(8, " "); CONVSTR.put(9, "\n"); CONVSTR.put(0, "");
		solve();flush();
	}
	//Don't have to see. end------------------------------------------
	static void solve(){//Here is the main function
  int N = nextInt();
  ArrayList<Integer> tmp = nextIntArray();
  int[] list = new int[N];
  for(int i = 0; i < N; i++){
  	list[i] = tmp.get(i);
  }
  HashSet<String> set = new HashSet<String>();
  int all = 0;
  int notall = 0;
  for(int i = 0; i < N; i++){
    if(list[i] >= 1 && list[i] <= 399 && !set.contains("gray")){
       set.add("gray");
      notall++;
    }
    if(list[i] >= 400 && list[i] <= 799 && !set.contains("brown")){
       set.add("brown");
      notall++;
    }
    if(list[i] >= 800 && list[i] <= 1199 && !set.contains("green")){
       set.add("green");
      notall++;
    }
    if(list[i] >= 1200 && list[i] <= 1599 && !set.contains("water")){
       set.add("water");
      notall++;
    }
    if(list[i] >= 1600 && list[i] <= 1999 && !set.contains("blue")){
       set.add("blue");
      notall++;
    }
    if(list[i] >= 2000 && list[i] <= 2399 && !set.contains("yellow")){
       set.add("yellow");
      notall++;
    }
    if(list[i] >= 2400 && list[i] <= 2799 && !set.contains("orange")){
       set.add("orange");
      notall++;
    }
    if(list[i] >= 2800 && list[i] <= 3199 && !set.contains("red")){
       set.add("red");
      notall++;
    }
    if(list[i] >= 3200){
       all++;
    }
  }
  myerr(set);
  int min = notall;
  int max = notall + all;
  if(min == 0 && all >= 1){
     min = 1;
  }
  myout(min + " " + max);
	}
	//Method addition frame start



	//Method addition frame end
}
