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. This code works for me. But i have a doubt how to
View Tutorial          By: Daya at 2015-05-04 12:04:19

2. Where to put the smsc number. I am using vodafone
View Tutorial          By: gopi at 2009-06-11 22:07:49

3. hiiiiiiii
View Tutorial          By: venkateshwarreddy suravaram at 2010-04-30 23:57:01

4. Actually in gallery example the images can be move
View Tutorial          By: santu at 2013-02-16 12:40:29

5. This article is help full for beginners.now i will
View Tutorial          By: shobha B at 2012-08-31 06:23:31

6. pl send me how to download java 2 micro edition do
View Tutorial          By: Narayana at 2013-02-21 10:08:27

7. Hi mounika, Did you download and install the javac
View Tutorial          By: Ramlak at 2008-04-27 05:49:42

8. Good one
View Tutorial          By: Ravi at 2007-11-19 03:30:40

9. one of the best example for trim()....
View Tutorial          By: sharad at 2013-01-29 13:43:58

10. This matter is really too good.
View Tutorial          By: Ashwin perti at 2009-07-08 04:43:55