    //Do what you can't.
     
    import java.io.*;
    import java.util.*;
    import java.math.BigInteger;
    public class Main{
      public static void main(String[] args) {
        InputReader in = new InputReader(System.in);
        PrintWriter w = new PrintWriter(System.out);
        int n = in.nextInt();
        int[] a = in.nextIntArray(n);
        boolean[] b = new boolean[8];
        int tt = 0;
        for (int i = 0; i < n; i++) {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        }
        int c = 0;
        for (int i = 0; i < 8; i++)
          if (b[i])
            c++;
        int mn = c;
        int mx = mn+tt;
        if (mn==0)
          mn=1;
        w.println(mn + " " + mx);
        w.close();
      }
      static class InputReader {
     
        private final InputStream stream;
        private final byte[] buf = new byte[8192];
        private int curChar, snumChars;
        private SpaceCharFilter filter;
     
        public InputReader(InputStream stream) {
          this.stream = stream;
        }
     
        public int snext() {
          if (snumChars == -1)
            throw new InputMismatchException();
          if (curChar >= snumChars) {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          }
          return buf[curChar++];
        }
     
        public int nextInt() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          int res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public long nextLong() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          long res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public int[] nextIntArray(int n) {
          int a[] = new int[n];
          for (int i = 0; i < n; i++) {
            a[i] = nextInt();
          }
          return a;
        }
     
        public String readString() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isSpaceChar(c));
          return res.toString();
        }
     
        public String nextLine() {
          int c = snext();
          while (isSpaceChar(c))
            c = snext();
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isEndOfLine(c));
          return res.toString();
        }
     
        public boolean isSpaceChar(int c) {
          if (filter != null)
            return filter.isSpaceChar(c);
          return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }
     
        private boolean isEndOfLine(int c) {
          return c == '\n' || c == '\r' || c == -1;
        }
     
        public interface SpaceCharFilter {
          public boolean isSpaceChar(int ch);
        }
      }
    } import java.io.*; io.* java import java.util.*; util.* java import java.math.BigInteger; BigInteger java.math public class Main{
      public static void main(String[] args) {
        InputReader in = new InputReader(System.in);
        PrintWriter w = new PrintWriter(System.out);
        int n = in.nextInt();
        int[] a = in.nextIntArray(n);
        boolean[] b = new boolean[8];
        int tt = 0;
        for (int i = 0; i < n; i++) {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        }
        int c = 0;
        for (int i = 0; i < 8; i++)
          if (b[i])
            c++;
        int mn = c;
        int mx = mn+tt;
        if (mn==0)
          mn=1;
        w.println(mn + " " + mx);
        w.close();
      }
      static class InputReader {
     
        private final InputStream stream;
        private final byte[] buf = new byte[8192];
        private int curChar, snumChars;
        private SpaceCharFilter filter;
     
        public InputReader(InputStream stream) {
          this.stream = stream;
        }
     
        public int snext() {
          if (snumChars == -1)
            throw new InputMismatchException();
          if (curChar >= snumChars) {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          }
          return buf[curChar++];
        }
     
        public int nextInt() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          int res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public long nextLong() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          long res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public int[] nextIntArray(int n) {
          int a[] = new int[n];
          for (int i = 0; i < n; i++) {
            a[i] = nextInt();
          }
          return a;
        }
     
        public String readString() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isSpaceChar(c));
          return res.toString();
        }
     
        public String nextLine() {
          int c = snext();
          while (isSpaceChar(c))
            c = snext();
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isEndOfLine(c));
          return res.toString();
        }
     
        public boolean isSpaceChar(int c) {
          if (filter != null)
            return filter.isSpaceChar(c);
          return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }
     
        private boolean isEndOfLine(int c) {
          return c == '\n' || c == '\r' || c == -1;
        }
     
        public interface SpaceCharFilter {
          public boolean isSpaceChar(int ch);
        }
      }
    } Main public static void main(String[] args) {
        InputReader in = new InputReader(System.in);
        PrintWriter w = new PrintWriter(System.out);
        int n = in.nextInt();
        int[] a = in.nextIntArray(n);
        boolean[] b = new boolean[8];
        int tt = 0;
        for (int i = 0; i < n; i++) {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        }
        int c = 0;
        for (int i = 0; i < 8; i++)
          if (b[i])
            c++;
        int mn = c;
        int mx = mn+tt;
        if (mn==0)
          mn=1;
        w.println(mn + " " + mx);
        w.close();
      } main {
        InputReader in = new InputReader(System.in);
        PrintWriter w = new PrintWriter(System.out);
        int n = in.nextInt();
        int[] a = in.nextIntArray(n);
        boolean[] b = new boolean[8];
        int tt = 0;
        for (int i = 0; i < n; i++) {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        }
        int c = 0;
        for (int i = 0; i < 8; i++)
          if (b[i])
            c++;
        int mn = c;
        int mx = mn+tt;
        if (mn==0)
          mn=1;
        w.println(mn + " " + mx);
        w.close();
      } InputReader in = new InputReader(System.in); in new InputReader(System.in) PrintWriter w = new PrintWriter(System.out); w new PrintWriter(System.out) int n = in.nextInt(); n in.nextInt() in.nextInt in int[] a = in.nextIntArray(n); a in.nextIntArray(n) in.nextIntArray in n boolean[] b = new boolean[8]; b new boolean[8] 8 int tt = 0; tt 0 for (int i = 0; i < n; i++) {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        } {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        } if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++; 1 <= a[i] && a[i] <= 399 1 <= a[i] 1 a[i] a i a[i] <= 399 a[i] a i 399 b[0] = true b[0] b 0 true if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++; 400 <= a[i] && a[i] <= 799 400 <= a[i] 400 a[i] a i a[i] <= 799 a[i] a i 799 b[1] = true b[1] b 1 true if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++; 800 <= a[i] && a[i] <= 1199 800 <= a[i] 800 a[i] a i a[i] <= 1199 a[i] a i 1199 b[2] = true b[2] b 2 true if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++; 1200 <= a[i] && a[i] <= 1599 1200 <= a[i] 1200 a[i] a i a[i] <= 1599 a[i] a i 1599 b[3] = true b[3] b 3 true if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++; 1600 <= a[i] && a[i] <= 1999 1600 <= a[i] 1600 a[i] a i a[i] <= 1999 a[i] a i 1999 b[4] = true b[4] b 4 true if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++; 2000 <= a[i] && a[i] <= 2399 2000 <= a[i] 2000 a[i] a i a[i] <= 2399 a[i] a i 2399 b[5] = true b[5] b 5 true if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++; 2400 <= a[i] && a[i] <= 2799 2400 <= a[i] 2400 a[i] a i a[i] <= 2799 a[i] a i 2799 b[6] = true b[6] b 6 true if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++; 2800 <= a[i] && a[i] <= 3199 2800 <= a[i] 2800 a[i] a i a[i] <= 3199 a[i] a i 3199 b[7] = true b[7] b 7 true if (a[i]>=3200)
            tt++; a[i]>=3200 a[i] a i 3200 tt++ tt int c = 0; c 0 for (int i = 0; i < 8; i++)
          if (b[i])
            c++; int i = 0; int i = 0; i 0 i < 8 i 8 i++ i++ i if (b[i])
            c++; if (b[i])
            c++; b[i] b i c++ c int mn = c; mn c int mx = mn+tt; mx mn+tt mn tt if (mn==0)
          mn=1; mn==0 mn 0 mn=1 mn 1 w.println(mn + " " + mx) w.println w mn + " " + mx mn + " " + mx mn " " mx w.close() w.close w String[] args args static class InputReader {
     
        private final InputStream stream;
        private final byte[] buf = new byte[8192];
        private int curChar, snumChars;
        private SpaceCharFilter filter;
     
        public InputReader(InputStream stream) {
          this.stream = stream;
        }
     
        public int snext() {
          if (snumChars == -1)
            throw new InputMismatchException();
          if (curChar >= snumChars) {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          }
          return buf[curChar++];
        }
     
        public int nextInt() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          int res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public long nextLong() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          long res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public int[] nextIntArray(int n) {
          int a[] = new int[n];
          for (int i = 0; i < n; i++) {
            a[i] = nextInt();
          }
          return a;
        }
     
        public String readString() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isSpaceChar(c));
          return res.toString();
        }
     
        public String nextLine() {
          int c = snext();
          while (isSpaceChar(c))
            c = snext();
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isEndOfLine(c));
          return res.toString();
        }
     
        public boolean isSpaceChar(int c) {
          if (filter != null)
            return filter.isSpaceChar(c);
          return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }
     
        private boolean isEndOfLine(int c) {
          return c == '\n' || c == '\r' || c == -1;
        }
     
        public interface SpaceCharFilter {
          public boolean isSpaceChar(int ch);
        }
      } InputReader private final InputStream stream; stream private final byte[] buf = new byte[8192]; buf new byte[8192] 8192 private int curChar curChar snumChars; snumChars private SpaceCharFilter filter; filter public InputReader(InputStream stream) {
          this.stream = stream;
        } InputReader {
          this.stream = stream;
        } this.stream = stream this.stream this this.stream stream InputStream stream stream public int snext() {
          if (snumChars == -1)
            throw new InputMismatchException();
          if (curChar >= snumChars) {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          }
          return buf[curChar++];
        } snext {
          if (snumChars == -1)
            throw new InputMismatchException();
          if (curChar >= snumChars) {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          }
          return buf[curChar++];
        } if (snumChars == -1)
            throw new InputMismatchException(); snumChars == -1 snumChars -1 1 throw new InputMismatchException(); new InputMismatchException() if (curChar >= snumChars) {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          } curChar >= snumChars curChar snumChars {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          } curChar = 0 curChar 0 try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            } catch (IOException e) {
              throw new InputMismatchException();
            } IOException e {
              throw new InputMismatchException();
            } throw new InputMismatchException(); new InputMismatchException() {
              snumChars = stream.read(buf);
            } snumChars = stream.read(buf) snumChars stream.read(buf) stream.read stream buf if (snumChars <= 0)
              return -1; snumChars <= 0 snumChars 0 return -1; -1 1 return buf[curChar++]; buf[curChar++] buf curChar++ curChar public int nextInt() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          int res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        } nextInt {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          int res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        } int c = snext(); c snext() snext while (isSpaceChar(c)) {
            c = snext();
          } isSpaceChar(c) isSpaceChar c {
            c = snext();
          } c = snext() c snext() snext int sgn = 1; sgn 1 if (c == '-') {
            sgn = -1;
            c = snext();
          } c == '-' c '-' {
            sgn = -1;
            c = snext();
          } sgn = -1 sgn -1 1 c = snext() c snext() snext int res = 0; res 0 do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c)); !isSpaceChar(c) isSpaceChar(c) isSpaceChar c {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } if (c < '0' || c > '9')
              throw new InputMismatchException(); c < '0' || c > '9' c < '0' c '0' c > '9' c '9' throw new InputMismatchException(); new InputMismatchException() res *= 10 res 10 res += c - '0' res c - '0' c '0' c = snext() c snext() snext return res * sgn; res * sgn res sgn public long nextLong() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          long res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        } nextLong {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          long res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        } int c = snext(); c snext() snext while (isSpaceChar(c)) {
            c = snext();
          } isSpaceChar(c) isSpaceChar c {
            c = snext();
          } c = snext() c snext() snext int sgn = 1; sgn 1 if (c == '-') {
            sgn = -1;
            c = snext();
          } c == '-' c '-' {
            sgn = -1;
            c = snext();
          } sgn = -1 sgn -1 1 c = snext() c snext() snext long res = 0; res 0 do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c)); !isSpaceChar(c) isSpaceChar(c) isSpaceChar c {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } if (c < '0' || c > '9')
              throw new InputMismatchException(); c < '0' || c > '9' c < '0' c '0' c > '9' c '9' throw new InputMismatchException(); new InputMismatchException() res *= 10 res 10 res += c - '0' res c - '0' c '0' c = snext() c snext() snext return res * sgn; res * sgn res sgn public int[] nextIntArray(int n) {
          int a[] = new int[n];
          for (int i = 0; i < n; i++) {
            a[i] = nextInt();
          }
          return a;
        } nextIntArray {
          int a[] = new int[n];
          for (int i = 0; i < n; i++) {
            a[i] = nextInt();
          }
          return a;
        } int a[] = new int[n]; a new int[n] n for (int i = 0; i < n; i++) {
            a[i] = nextInt();
          } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            a[i] = nextInt();
          } {
            a[i] = nextInt();
          } a[i] = nextInt() a[i] a i nextInt() nextInt return a; a int n n public String readString() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isSpaceChar(c));
          return res.toString();
        } readString {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isSpaceChar(c));
          return res.toString();
        } int c = snext(); c snext() snext while (isSpaceChar(c)) {
            c = snext();
          } isSpaceChar(c) isSpaceChar c {
            c = snext();
          } c = snext() c snext() snext StringBuilder res = new StringBuilder(); res new StringBuilder() do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isSpaceChar(c)); !isSpaceChar(c) isSpaceChar(c) isSpaceChar c {
            res.appendCodePoint(c);
            c = snext();
          } res.appendCodePoint(c) res.appendCodePoint res c c = snext() c snext() snext return res.toString(); res.toString() res.toString res public String nextLine() {
          int c = snext();
          while (isSpaceChar(c))
            c = snext();
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isEndOfLine(c));
          return res.toString();
        } nextLine {
          int c = snext();
          while (isSpaceChar(c))
            c = snext();
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isEndOfLine(c));
          return res.toString();
        } int c = snext(); c snext() snext while (isSpaceChar(c))
            c = snext(); isSpaceChar(c) isSpaceChar c c = snext() c snext() snext StringBuilder res = new StringBuilder(); res new StringBuilder() do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isEndOfLine(c)); !isEndOfLine(c) isEndOfLine(c) isEndOfLine c {
            res.appendCodePoint(c);
            c = snext();
          } res.appendCodePoint(c) res.appendCodePoint res c c = snext() c snext() snext return res.toString(); res.toString() res.toString res public boolean isSpaceChar(int c) {
          if (filter != null)
            return filter.isSpaceChar(c);
          return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        } isSpaceChar {
          if (filter != null)
            return filter.isSpaceChar(c);
          return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        } if (filter != null)
            return filter.isSpaceChar(c); filter != null filter null return filter.isSpaceChar(c); filter.isSpaceChar(c) filter.isSpaceChar filter c return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1; c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1 c == '\t' c == '\r' c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1 c == ' ' c ' ' c == '\n' c '\n' c == '\r' c '\r' c == '\t' c '\t' c == -1 c -1 1 int c c private boolean isEndOfLine(int c) {
          return c == '\n' || c == '\r' || c == -1;
        } isEndOfLine {
          return c == '\n' || c == '\r' || c == -1;
        } return c == '\n' || c == '\r' || c == -1; c == '\n' || c == '\r' || c == -1 c == '\n' || c == '\r' || c == -1 c == '\n' c '\n' c == '\r' c '\r' c == -1 c -1 1 int c c public interface SpaceCharFilter {
          public boolean isSpaceChar(int ch);
        } SpaceCharFilter public boolean isSpaceChar(int ch); isSpaceChar int ch ch public class Main{
      public static void main(String[] args) {
        InputReader in = new InputReader(System.in);
        PrintWriter w = new PrintWriter(System.out);
        int n = in.nextInt();
        int[] a = in.nextIntArray(n);
        boolean[] b = new boolean[8];
        int tt = 0;
        for (int i = 0; i < n; i++) {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        }
        int c = 0;
        for (int i = 0; i < 8; i++)
          if (b[i])
            c++;
        int mn = c;
        int mx = mn+tt;
        if (mn==0)
          mn=1;
        w.println(mn + " " + mx);
        w.close();
      }
      static class InputReader {
     
        private final InputStream stream;
        private final byte[] buf = new byte[8192];
        private int curChar, snumChars;
        private SpaceCharFilter filter;
     
        public InputReader(InputStream stream) {
          this.stream = stream;
        }
     
        public int snext() {
          if (snumChars == -1)
            throw new InputMismatchException();
          if (curChar >= snumChars) {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          }
          return buf[curChar++];
        }
     
        public int nextInt() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          int res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public long nextLong() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          long res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public int[] nextIntArray(int n) {
          int a[] = new int[n];
          for (int i = 0; i < n; i++) {
            a[i] = nextInt();
          }
          return a;
        }
     
        public String readString() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isSpaceChar(c));
          return res.toString();
        }
     
        public String nextLine() {
          int c = snext();
          while (isSpaceChar(c))
            c = snext();
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isEndOfLine(c));
          return res.toString();
        }
     
        public boolean isSpaceChar(int c) {
          if (filter != null)
            return filter.isSpaceChar(c);
          return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }
     
        private boolean isEndOfLine(int c) {
          return c == '\n' || c == '\r' || c == -1;
        }
     
        public interface SpaceCharFilter {
          public boolean isSpaceChar(int ch);
        }
      }
    } public class Main{
      public static void main(String[] args) {
        InputReader in = new InputReader(System.in);
        PrintWriter w = new PrintWriter(System.out);
        int n = in.nextInt();
        int[] a = in.nextIntArray(n);
        boolean[] b = new boolean[8];
        int tt = 0;
        for (int i = 0; i < n; i++) {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        }
        int c = 0;
        for (int i = 0; i < 8; i++)
          if (b[i])
            c++;
        int mn = c;
        int mx = mn+tt;
        if (mn==0)
          mn=1;
        w.println(mn + " " + mx);
        w.close();
      }
      static class InputReader {
     
        private final InputStream stream;
        private final byte[] buf = new byte[8192];
        private int curChar, snumChars;
        private SpaceCharFilter filter;
     
        public InputReader(InputStream stream) {
          this.stream = stream;
        }
     
        public int snext() {
          if (snumChars == -1)
            throw new InputMismatchException();
          if (curChar >= snumChars) {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          }
          return buf[curChar++];
        }
     
        public int nextInt() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          int res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public long nextLong() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          long res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public int[] nextIntArray(int n) {
          int a[] = new int[n];
          for (int i = 0; i < n; i++) {
            a[i] = nextInt();
          }
          return a;
        }
     
        public String readString() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isSpaceChar(c));
          return res.toString();
        }
     
        public String nextLine() {
          int c = snext();
          while (isSpaceChar(c))
            c = snext();
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isEndOfLine(c));
          return res.toString();
        }
     
        public boolean isSpaceChar(int c) {
          if (filter != null)
            return filter.isSpaceChar(c);
          return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }
     
        private boolean isEndOfLine(int c) {
          return c == '\n' || c == '\r' || c == -1;
        }
     
        public interface SpaceCharFilter {
          public boolean isSpaceChar(int ch);
        }
      }
    } Main
    //Do what you can't.
     
    import java.io.*;
    import java.util.*;
    import java.math.BigInteger;
    public class Main{
      public static void main(String[] args) {
        InputReader in = new InputReader(System.in);
        PrintWriter w = new PrintWriter(System.out);
        int n = in.nextInt();
        int[] a = in.nextIntArray(n);
        boolean[] b = new boolean[8];
        int tt = 0;
        for (int i = 0; i < n; i++) {
          if (1 <= a[i] && a[i] <= 399)
            b[0] = true;
          else if (400 <= a[i] && a[i] <= 799)
            b[1] = true;
          else if (800 <= a[i] && a[i] <= 1199)
            b[2] = true;
          else if (1200 <= a[i] && a[i] <= 1599)
            b[3] = true;
          else if (1600 <= a[i] && a[i] <= 1999)
            b[4] = true;
          else if (2000 <= a[i] && a[i] <= 2399)
            b[5] = true;
          else if (2400 <= a[i] && a[i] <= 2799)
            b[6] = true;
          else if (2800 <= a[i] && a[i] <= 3199)
            b[7] = true;
          else if (a[i]>=3200)
            tt++;
     
        }
        int c = 0;
        for (int i = 0; i < 8; i++)
          if (b[i])
            c++;
        int mn = c;
        int mx = mn+tt;
        if (mn==0)
          mn=1;
        w.println(mn + " " + mx);
        w.close();
      }
      static class InputReader {
     
        private final InputStream stream;
        private final byte[] buf = new byte[8192];
        private int curChar, snumChars;
        private SpaceCharFilter filter;
     
        public InputReader(InputStream stream) {
          this.stream = stream;
        }
     
        public int snext() {
          if (snumChars == -1)
            throw new InputMismatchException();
          if (curChar >= snumChars) {
            curChar = 0;
            try {
              snumChars = stream.read(buf);
            } catch (IOException e) {
              throw new InputMismatchException();
            }
            if (snumChars <= 0)
              return -1;
          }
          return buf[curChar++];
        }
     
        public int nextInt() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          int res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public long nextLong() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          int sgn = 1;
          if (c == '-') {
            sgn = -1;
            c = snext();
          }
          long res = 0;
          do {
            if (c < '0' || c > '9')
              throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = snext();
          } while (!isSpaceChar(c));
          return res * sgn;
        }
     
        public int[] nextIntArray(int n) {
          int a[] = new int[n];
          for (int i = 0; i < n; i++) {
            a[i] = nextInt();
          }
          return a;
        }
     
        public String readString() {
          int c = snext();
          while (isSpaceChar(c)) {
            c = snext();
          }
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isSpaceChar(c));
          return res.toString();
        }
     
        public String nextLine() {
          int c = snext();
          while (isSpaceChar(c))
            c = snext();
          StringBuilder res = new StringBuilder();
          do {
            res.appendCodePoint(c);
            c = snext();
          } while (!isEndOfLine(c));
          return res.toString();
        }
     
        public boolean isSpaceChar(int c) {
          if (filter != null)
            return filter.isSpaceChar(c);
          return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }
     
        private boolean isEndOfLine(int c) {
          return c == '\n' || c == '\r' || c == -1;
        }
     
        public interface SpaceCharFilter {
          public boolean isSpaceChar(int ch);
        }
      }
    }