You are here
Home >

Which of these classes is not part of Java collection framework?

Which of these classes is not part of Java’s collection framework?

A) Maps
B) Array
C) Stack
D) Queue

Answer: B) Array

Explanation: Array is not part of Java’s Collection Framework. Array is a fundamental data structure in Java and can be used within collections. It is a core part of the Java language itself, used for creating arrays that can hold fixed-size sequences of elements.

Map (not Maps) is a part of collection framework, but it doesn’t inherit from the Collection interface.

Stack, and Queue are part of the Collection Framework as they represent different types of collections (Stack for LIFO data structures, and Queue for FIFO data structures).


Top