This task will require some thinking! Which mutable collection type can the following methods and properties belong to?
Tip: Please be attentive: some operations can belong to multiple collection types and even apply to all three!
This task will require some thinking! Which mutable collection type can the following methods and properties belong to?
Tip: Please be attentive: some operations can belong to multiple collection types and even apply to all three!
| List | Set | Map | |
|---|---|---|---|
| size | |||
| clear() | |||
| subList(fromIndex, toIndex) | |||
| isEmpty() | |||
| put(key, value) | |||
| add(element) |
Create a free account to access the full topic