CodeSnippet:
public static boolean isNumeric (String inputstring ){ for (int i = 0; i < inputstring.length(); i++) { //If we find a non-digit character we return false. if (!Character. isDigit(inputstring. charAt(i ))) return false; } return true; }
|