docs: public static String pad(String s, int length)
    {
      if (s.length() < length)
      {
        StringBuffer a = new StringBuffer(length);
        a.append(s);
        for (int i = s.length(); i < length; i++)
        {
          a = a.append(" ");
        }
        return a.toString();
      }
      else if (s.length() > length)
      {
        return s.substring(0, length);
      }
      else
      {
        return s;
      }
    }