public boolean isNumber(String s) {
        if(s == null) return false;
        s = s.trim();
        if(s.length() == 0) return false;
        if(s.contains("e")) {
        	int index = s.indexOf('e');
        	// ?e[int], after e, it must be int, rather than float
        	return validNum(s.substring(0, index)) 
        			&& validInt(s.substring(index + 1, s.length()), false, true);
        } else {
        	return validNum(s);
        }
    }