Comment on Tutorial - How to use ArrayList in Java By Hong



Comment Added by : ADC

Comment Added at : 2010-02-25 18:43:32

Comment on Tutorial : How to use ArrayList in Java By Hong
I entered four different objects into an ArrayList using the add function.

when I want to list the contents as per your example, the most recent entry appears to occupy all four positions in the list.

This cannot be. Do you know what the source of the problem is?


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. Please provide web.xml for the example
View Tutorial          By: Amit at 2008-12-24 02:16:59

2. Amazing new function atoi() , it shows c,c++ are p
View Tutorial          By: Hari at 2009-05-05 22:20:17

3. hello
thanks for your code
It works

View Tutorial          By: m_karimi at 2008-10-24 12:08:06

4. Good example for vector
View Tutorial          By: mangai at 2011-07-07 09:46:10

5. Enabling IPV6 at Application Level


View Tutorial          By: i want code , can you send me at 2014-12-28 11:43:35

6. Works thnx :D :D :D :D
View Tutorial          By: nik at 2014-11-09 20:44:29

7. Detect OS of iphone using Java Code
View Tutorial          By: Naina at 2012-07-31 11:07:09

8. i am getting force closed with this code...

View Tutorial          By: kamlapati at 2011-07-16 06:06:31

9. can you please e mail me a code about hotel reserv
View Tutorial          By: princeton at 2008-09-19 02:32:13

10. Thanks for this section. Clears most of my doubts.
View Tutorial          By: Melvin at 2008-07-05 04:54:19