Search This Blog

Monday, June 19, 2006

How can you minimize the need of garbage collection and make the memory use more effective?

Ans:Use object pooling and weak object references.

You are planning to do an indexed search in a list of objects. Which of the two Java collections should you use: ArrayList or LinkedList?
Ans: ArrayList

No comments: