Board index » jbuilder » ArrayIndexOutOfBoundsException 3 >= 3

ArrayIndexOutOfBoundsException 3 >= 3


2004-04-28 03:31:41 AM
jbuilder16
This should be "3>= 2", as there are only 2 elements and the index was set to
3.
--
Raymond Kennington
Programming Solutions
TeamW2W (InfoPower)
 
 

Re:ArrayIndexOutOfBoundsException 3 >= 3

Raymond Kennington wrote:
Quote
This should be "3>= 2", as there are only 2 elements and the index was set to
3.
Is this a question? Is there some background here that we should be
aware of.
If you have an array of 3 objects, you can't access obj[3]. That'll give
you an ArrayIndexOutOfBoundsException, with exactly this message.
 

Re:ArrayIndexOutOfBoundsException 3 >= 3

Shankar Unni wrote:
Quote
Raymond Kennington wrote:

>This should be "3>= 2", as there are only 2 elements and the index
>was set to
>3.

Is this a question? Is there some background here that we should be
aware of.
Either way, if there's some bug in the way ArrayOutOfBoundsExceptions
are being generated in your program, it's not a bug in the JBuilder IDE.
If there's a bug (which I sort of doubt, since it's a pretty
fundamental thing), it's a bug in the Java libraries.
--
Gillmer J. Derge (TeamB)
 

{smallsort}