1.

Which Method Can Be Used To Increase The Capacity Of Arraylist Object Manually?

Answer»

When we add an element, the capacity of ArrayList OBJECT increases automatically, but we can INCREASE it manually to SPECIFIED length X by using function ensureCapacity(x);

When we add an element, the capacity of ArrayList object increases automatically, but we can increase it manually to specified length x by using function ensureCapacity(x);



Discussion

No Comment Found

Related InterviewSolutions