<?php
  declare(strict_types=1);

  fscanf(STDIN, "%i", $n);
  $xs = explode(" ", fgets(STDIN));

  $i = 0;
  $wildcards = 0;
  while ($i < $n)
  {
      $c = (int)($xs[$i] / 400);
      if ($c >= 8)
      {
          ++$wildcards;
      }
      else
      {
          $colors[$c] = 1;
      }

      ++$i;
  }

  $num_given = array_sum($colors);
  echo $num_given, " ", min(8, $num_given + $wildcards), PHP_EOL;
