java - Find character in a number which is in String format -


how can find string in number?

a simple example follows

private char check() {         string sample ="1212kkk";//121hhh444 | 12-22         return 'k';//'h' | '-'      } 

if other number want return value.

how can first character ring?

try this:

string result = sample.replaceall("\\d" ,""); return result; 

Comments

Popular posts from this blog

Perl - how to grep a block of text from a file -

delphi - How to remove all the grips on a coolbar if I have several coolbands? -

javascript - Animating array of divs; only the final element is modified -