code: int[] peek(int n) throws
        IOException
    {
      int[] buf = new int[n];
      Mark m = mark();
      boolean seenEOF = false;
  
      for (int i = 0; i < buf.length; i++)
      {
        if (!seenEOF)
        {
          buf[i] = next();
        }
        else
        {
          buf[i] = -1;
        }
        if (buf[i] == -1)
        {
          seenEOF = true;
        }
      }
      if (!seenEOF)
      {
        unread(buf, m);
      }
      else
      {
        List<Integer> ints = Lists.newArrayList();
        for (int aBuf : buf)
        {
          ints.add(aBuf);
          if (aBuf == -1)
          {
            break;
          }
        }
        unread(ints, m);
      }
  
      return buf;
    }
docs: Returns the the next n characters in the stream without advancing the
  readers position.
  
  @param n the number of characters to read
  @return An array with guaranteed length n, with -1 being the value for
  all elements at and after EOF.
  @throws IOException