Java: method to get position of a match in a String?

Posted by HH on Stack Overflow See other posts from Stack Overflow or by HH
Published on 2010-04-11T01:44:15Z Indexed on 2010/04/11 1:53 UTC
Read the original article Hit count: 264

Filed under:
|
|
|
String match = "hello";
String text = "0123456789hello0123456789";

int position = getPosition(match, text); // should be 10, is there such a method?

© Stack Overflow or respective owner

Related posts about java

Related posts about beginner