Top "Collections" questions

Collections APIs provide developers with a set of classes and interfaces that make it easier to handle collections of objects.

Kotlin's List missing "add", "remove", Map missing "put", etc?

In Java we could do the following public class TempClass { List<Integer> myList = null; void doSomething() { myList = new …

collections kotlin
How do I overload the square-bracket operator in C#?

DataGridView, for example, lets you do this: DataGridView dgv = ...; DataGridViewCell cell = dgv[1,5]; but for the life of me I can't …

c# collections operators operator-overloading
Determining whether an object is a member of a collection in VBA

How do I determine whether an object is a member of a collection in VBA? Specifically, I need to find …

vba object ms-access collections
What .NET collection provides the fastest search

I have 60k items that need to be checked against a 20k lookup list. Is there a collection object (like …

c# .net search collections
ArrayList: how does the size increase?

I have a basic question on Java ArrayList. When ArrayList is declared and initialized using the default constructor, memory space …

java arrays arraylist collections
UnmodifiableMap (Java Collections) vs ImmutableMap (Google)

Context I need to return a reference to a map that I'm using for a data cache, and I'd like …

java collections map guava
Magento: Set LIMIT on collection

The question that I tried to find out was how do we set a Limit on a Collection, the answers …

magento collections
ArrayList - How to modify a member of an object?

I have a number of Customer objects stored in an ArrayList. My Customer class has 2 data members: Name and Email. …

java collections pojo
Size-limited queue that holds last N elements in Java

A very simple & quick question on Java libraries: is there a ready-made class that implements a Queue with a …

collections queue java
Select N random elements from a List<T> in C#

I need a quick algorithm to select 5 random elements from a generic list. For example, I'd like to get 5 random …

c# algorithm collections random element