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



Comment Added by : arya

Comment Added at : 2012-11-07 08:37:59

Comment on Tutorial : indexOf( ) and lastIndexOf( ) in Java By Hong
import java.io.*;
class lastindexof
{
public static void main(String argv[]) throws IOException
{
String mystr;
BufferedReader bf=new BufferedReader(new InputStreamReader(System.in));
System.out.print("enter the string");
mystr=bf.readLine();
System.out.println(" character at position is=" +mystr.lastIndexOf());
}
}

why this program always showing me cannot find symbol error


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. int iNum2 = parseInt(“0xA”); //returns
View Tutorial          By: Doug Whitehead at 2008-12-01 21:27:55

2. Gracias, it worked.
View Tutorial          By: Eduardo at 2009-09-09 12:16:30

3. hi,
i am safeer, i am try this program in

View Tutorial          By: Safi at 2009-05-22 22:32:04

4. Very Nice and Perfectly Understandable.....
View Tutorial          By: rex at 2015-04-16 12:27:03

5. Hi
I can able to execute the abov

View Tutorial          By: sruthy at 2010-07-23 03:29:39

6. Thank you , It is really good for beginners.
View Tutorial          By: Satish Kumar at 2010-01-18 03:06:49

7. thnx, 4 ur explanation, that was usefl
but

View Tutorial          By: some1 at 2009-04-28 03:26:28

8. i created report. but i move to second page all de
View Tutorial          By: nadeekadn at 2012-04-30 10:11:42

9. Thank You So Much . .. .. .
Very Nice Expl

View Tutorial          By: salman at 2012-07-05 13:22:11

10. This is very helpfull to us.........thnq
View Tutorial          By: lavanya at 2012-03-17 05:43:12