x


ArrayLists vs Generic Lists

What's the difference between the two? Which is better - are ArrayLists better than Generic Lists in some cases, which?

more ▼

asked May 14 '11 at 02:01 AM

ina gravatar image

ina
3.4k 500 554 615

(comments are locked)
10|3000 characters needed characters left

1 answer: sort voted first

ArrayLists are only useful if you have to put different types of objects into a collection. They are slower than generic Lists. Lists are slower than built-in arrays, but they are mutable.

http://answers.unity3d.com/questions/48404/what-is-better-on-iphone-arraylist-or-listt

http://answers.unity3d.com/questions/40808/array-vs-arraylist

Google ArrayList vs Generic List for more details.

more ▼

answered May 14 '11 at 02:59 AM

Jessy gravatar image

Jessy
15.7k 72 95 198

You can use List if you want multiple object types in a generic list.

May 14 '11 at 05:29 AM yoyo
(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x382
x208
x155
x74
x8

asked: May 14 '11 at 02:01 AM

Seen: 4121 times

Last Updated: May 14 '11 at 02:01 AM