Try creating your List like this and see what happens.

List<int> alist =new ArrayList<int>(); 

-----Original Message-----
From: Peter [mailto:[EMAIL PROTECTED] 
Sent: Monday, May 21, 2007 2:29 AM
To: Tomcat Users List
Subject: Re: hi,wired problem? add 0 into alist but get 1 as a result!

thanks

i am sure that i put 0 in to a list and i am not badly display result and it
is the same list and it is only occur in this project.
thanks for any idea


On 5/21/07, David Delbecq <[EMAIL PROTECTED]> wrote:
>
> Never heard of such problem. Check your code. Either you add 1 to 
> list, not 0, either you badly display result, either it's not the same
list.
> Peter a écrit :
> > hi all,
> >
> > I have come into a very wired problem.
> >
> > here it is.
> > my project using JBuilder 2006 and tomcat 5.5.20.
> > when i put a 0 into a list and get 1 as a result.
> > simple code for testing!
> >
> > List alist =new ArrayList();
> > alist.add(0); put 0 into it
> > alist.get(0); get 1 as result.
> >
> > it occurs when i using JBuilder2006 to complie it and run under 
> > tomcat 5.5.20.
> > i choose Jbuilder 2006 builder property: language features ( java 2 
> > SDK V5.0generic enable) ; target VM java 2 SDK V5.0 and later
> >
> > but if i choose target VM target VM java 2 SDK V1.4 and later it 
> > works fine, put 0 get 0.
> > and if i donot run under the tomcat it still fine
> >
> > so i create another small project, in a jsp only doing List alist 
> > =new ArrayList(); alist.add(0); alist.get(0); and it works fine as 
> > well under the same tomcat.
> >
> >
> > i wonder what happens here?
> > my project using many other jar file , i wonder if there is 
> > something wrong there.
> > does anyone has a idea?
> >
> > thanks in advanced!
> >
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, 
> e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to