Java Interview Questions interview questions
Collections • ArrayDeque as a Queue, Collections • ArrayDeque as a Stack, Collections • ArrayList vs LinkedList, Collections • Comparable vs Comparator, Collections • HashMap Internals, Collections • HashSet Membership and Deduplication
400 questions with answers and explanations
Questions (page 1 of 8)
- When should a Java developer choose ArrayDeque as a Stack deliberately?Multiple choiceMedium
- When should a Java developer choose TreeSet and NavigableSet deliberately?Multiple choiceMedium
- In Java, which comparison about ExecutorService, Future, and CompletableFuture is accurate?Multiple choiceEasy
- Which practice avoids a common mistake with Java Memory Model, volatile, and synchronized?Multiple choiceMedium
- When should a Java developer choose ConcurrentSkipListMap deliberately?Multiple choiceMedium
- In Java, which comparison about ArrayList vs LinkedList is accurate?Multiple choiceEasy
- What deeper point about ArrayList vs LinkedList should a senior Java developer mention?Multiple choiceHard
- Which practice avoids a common mistake with equals() vs ==?Multiple choiceMedium
- What deeper point about CopyOnWriteArrayList should a senior Java developer mention?Multiple choiceHard
- Which statement about CopyOnWriteArrayList is the strongest interview answer?Multiple choiceEasy
- What deeper point about Thread Lifecycle and Creation should a senior Java developer mention?Multiple choiceHard
- Which practice avoids a common mistake with CopyOnWriteArrayList?Multiple choiceMedium
- What deeper point about ConcurrentSkipListMap should a senior Java developer mention?Multiple choiceHard
- When should a Java developer choose ArrayList vs LinkedList deliberately?Multiple choiceMedium
- In Java, which comparison about TreeSet and NavigableSet is accurate?Multiple choiceEasy
- When should a Java developer choose ConcurrentLinkedQueue deliberately?Multiple choiceMedium
- In Java, which comparison about List, Set, and Map is accurate?Multiple choiceEasy
- Which practice avoids a common mistake with ExecutorService, Future, and CompletableFuture?Multiple choiceMedium
- When should a Java developer choose HashMap Internals deliberately?Multiple choiceMedium
- In Java, which comparison about TreeMap and NavigableMap is accurate?Multiple choiceEasy
- Which practice avoids a common mistake with ArrayDeque as a Stack?Multiple choiceMedium
- Which practice avoids a common mistake with HashSet Membership and Deduplication?Multiple choiceMedium
- Which statement about Primitive Types and Wrappers is the strongest interview answer?Multiple choiceEasy
- In Java, which comparison about Immutable Class Design is accurate?Multiple choiceEasy
- Which statement about HashMap Internals is the strongest interview answer?Multiple choiceEasy
- Which practice avoids a common mistake with Immutable Class Design?Multiple choiceMedium
- When should a Java developer choose ArrayDeque as a Queue deliberately?Multiple choiceMedium
- Which practice avoids a common mistake with LinkedHashMap and Iteration Order?Multiple choiceMedium
- When should a Java developer choose Immutable Class Design deliberately?Multiple choiceMedium
- Which practice avoids a common mistake with List, Set, and Map?Multiple choiceMedium
- In Java, which comparison about ConcurrentHashMap and Concurrent Collections is accurate?Multiple choiceEasy
- Which statement about HashSet Membership and Deduplication is the strongest interview answer?Multiple choiceEasy
- In Java, which comparison about Comparable vs Comparator is accurate?Multiple choiceEasy
- Which practice avoids a common mistake with equals() and hashCode() Contract?Multiple choiceMedium
- Which practice avoids a common mistake with ArrayList vs LinkedList?Multiple choiceMedium
- Which practice avoids a common mistake with ConcurrentSkipListMap?Multiple choiceMedium
- Which statement about List, Set, and Map is the strongest interview answer?Multiple choiceEasy
- Which practice avoids a common mistake with TreeMap and NavigableMap?Multiple choiceMedium
- What deeper point about BlockingQueue and Producer-Consumer should a senior Java developer mention?Multiple choiceHard
- What deeper point about PriorityQueue and Heap Basics should a senior Java developer mention?Multiple choiceHard
- What deeper point about TreeMap and NavigableMap should a senior Java developer mention?Multiple choiceHard
- In Java, which comparison about Deadlocks and Race Conditions is accurate?Multiple choiceEasy
- Which statement about HashSet vs TreeSet is the strongest interview answer?Multiple choiceEasy
- Which practice avoids a common mistake with LRU Cache with LinkedHashMap?Multiple choiceMedium
- In Java, which comparison about Primitive Types and Wrappers is accurate?Multiple choiceEasy
- What deeper point about HashMap Internals should a senior Java developer mention?Multiple choiceHard
- When should a Java developer choose ExecutorService, Future, and CompletableFuture deliberately?Multiple choiceMedium
- What deeper point about Immutable Class Design should a senior Java developer mention?Multiple choiceHard
- Which statement about Immutable Class Design is the strongest interview answer?Multiple choiceEasy
- When should a Java developer choose Thread Lifecycle and Creation deliberately?Multiple choiceMedium