code: public static String readlineFromStdIn() throws IOException {
  		StringBuilder ret = new StringBuilder();
  		int c;
  		while ((c = System.in.read()) != '\n' && c != -1) {
  			if (c != '\r')
  				ret.append((char) c);
  		}
  		return ret.toString();
  	}
docs: Reads a line from standard input.
  
  @throws java.io.IOException if any.
  @return a {@link java.lang.String} object.