Comment on Tutorial - indexOf( ) and lastIndexOf( ) in Java By Hong



Comment Added by : Mike

Comment Added at : 2010-10-14 20:09:31

Comment on Tutorial : indexOf( ) and lastIndexOf( ) in Java By Hong
To "need help":

String str = "xR-MxR-MHelloxR-M";
System.out.println(str.substring(str.lastIndexOf("M", 15)+1, str.lastIndexOf("x")));

;-)


View Tutorial



Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. Thank you for giving info.
View Tutorial          By: Deepak cheela at 2013-01-23 07:03:08

2. Hello,

I am still getting the below

View Tutorial          By: pavithra at 2012-03-25 19:33:38

3. very superb
View Tutorial          By: bala at 2008-05-14 04:49:24

4. Hello friends ,
I have downloaded all 5 fil

View Tutorial          By: pinnacle at 2013-06-08 13:08:55

5. hey good code woww. this code lot of help me much
View Tutorial          By: vaibhav malpani at 2015-03-25 05:48:50

6. haii...
I am Ahmed , i am in 3rd btech ,

View Tutorial          By: Ahmed at 2014-08-09 06:30:11

7. I want to know about all java application.
View Tutorial          By: Ahasan at 2009-04-10 09:42:48

8. Good and very clear explanation...
View Tutorial          By: Pavana at 2010-01-05 23:35:30

9. Hi it really works fin great in my case.
Th

View Tutorial          By: Dnyan at 2007-12-31 02:03:40

10. works like a charm, though i didn't understand why
View Tutorial          By: primus at 2010-05-19 04:46:18