code: public static String capitalize(final String input) throws IllegalArgumentException {
          if (input == null) {
              throw new IllegalArgumentException("input can't be null");
          }
          if (input.length() == 0) {
              return "";
          }
          return head(input).map(String::toUpperCase).map(h -> tail(input).map(t -> h + t.toLowerCase()).orElse(h)).get();
      }
docs: Converts the first character of string to upper case and the remaining to lower case.
  
  @param input The string to capitalize
  @return The capitalized string