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



Subscribe to Tutorials

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. Hi, If any body was able to send the message suces
View Tutorial          By: kavin at 2011-03-14 06:24:18

2. thank you very much....
View Tutorial          By: divya at 2013-01-06 15:50:43

3. Thnx A Lot...very healpful...........
View Tutorial          By: vinay at 2012-07-19 09:21:20

4. The following line in the code
((NewThread)

View Tutorial          By: Carlos at 2009-11-18 14:34:51

5. If you are working with the multi-threaded program
View Tutorial          By: Prithvi at 2010-01-07 10:24:12

6. I wont to know about every thing of java
View Tutorial          By: susantha at 2009-10-11 09:35:40

7. EJB's can be deployed on multiple servers and when
View Tutorial          By: Tomek at 2011-09-12 12:29:07

8. @pawan: Wow. Your comment is museum-quality art, a
View Tutorial          By: Steve at 2013-02-21 20:30:47

9. Did you happen to import any certificates to execu
View Tutorial          By: Shashank at 2013-03-15 12:17:50

10. Excellent
View Tutorial          By: Jaleel at 2009-10-16 23:22:52