java.lang.StringIndexOutOfBoundsException: String ind ex out of range: 1

Coderanch | mark donner | 6 years ago
tip
Do you find the tips below useful? Click on the to mark them and say thanks to rafael . Or join the community to write better ones.
  1. 0

    using methods and counting uppercase characters

    Coderanch | 6 years ago | mark donner
    java.lang.StringIndexOutOfBoundsException: String ind ex out of range: 1
  2. 0
    samebug tip
    Thrown by String methods to indicate that an index is either negative or greater than the size of the string. For some methods such as the charAt method, this exception also is thrown when the index is equal to the size of the string.
  3. 0

    StringIndexOutOfBoundsException in a broken snippet.

    GitHub | 3 years ago | jdkessinger
    java.lang.StringIndexOutOfBoundsException: String index out of range: 4
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    why i am geeting this error

    Stack Overflow | 5 years ago | Sonal Akhal
    java.lang.StringIndexOutOfBoundsException: String index out of range: 3
  6. 0

    java String - String index out of range , charAt

    Stack Overflow | 5 years ago | user1551954
    java.lang.StringIndexOutOfBoundsException: String index out of range: 6

  1. poroszd 12 times, last 1 week ago
  2. linxiaolong 1 times, last 2 months ago
  3. jokester 1 times, last 3 months ago
  4. tyson925 1 times, last 3 months ago
  5. Torasque 1 times, last 4 months ago
11 more registered users
18 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.StringIndexOutOfBoundsException

    String ind ex out of range: 1

    at java.lang.String.charAt()
  2. Java RT
    String.charAt
    1. java.lang.String.charAt(String.java:695)
    1 frame
  3. Unknown
    test.main
    1. test.countUppercase(test.java:24)
    2. test.main(test.java:10)
    2 frames