Obtaining arraylist from array

Hi,

I want to make a growable array from an array without using existing arraylist.

Need more information on how they have implemented a growable array.

Why cant we create our own implementation.

what are difficulties we will face while implementing the same.

Thanks

Vijay Kumar

[321 byte] By [Vijaybiharia] at [2007-11-27 3:18:50]
# 1

> I want to make a growable array from an array without

> using existing arraylist.

First question is why?

> Need more information on how they have implemented a

> growable array.

The growth policy isn't specified but last time I looked they increase it by a factor of 1.5 every time growth is needed.

> Why cant we create our own implementation.

You can, just extend AbstractList, very easy.

> what are difficulties we will face while implementing

> the same.

Very few. Just read the AbstractList Javadoc. You realize this question is inconsistent with the previous one?

ejpa at 2007-7-12 8:21:29 > top of Java-index,Core,Core APIs...