Java Collections and Streams

Holding data in the right Java collection, and transforming it without writing a loop.

  • 9 topics
  • 78 cards
  • 47 questions
  • Intermediate to Advanced
Share

Collections

Choosing where data lives, and what that choice costs.

  • The Java Collections Framework: List, Set and Queue, what each promises, and which type to declare a variable with.

    Intermediate to Advanced8 cards · 5 qnot started

  • ArrayList vs LinkedList: two lists with the same methods and opposite costs, how an ArrayList grows, and removing while iterating.

    Intermediate to Advanced8 cards · 6 qnot started

  • Sets and queues: collections that decide what counts as a duplicate and what comes out next, and which class to use.

    Intermediate to Advanced8 cards · 5 qnot started

  • How a HashMap works: hashing to a bucket, collisions, resizing, the three map classes, and null keys.

    Intermediate to Advanced9 cards · 5 qnot started

  • Sorting your own types in Java: Comparable for the natural order, Comparator for the rest, and the two ways a comparator goes wrong.

    Intermediate to Advanced9 cards · 5 qnot started

Pipelines

Type parameters, lambdas and streams, and the loops they remove.

  • Java generics: type parameters, what the compiler checks, type erasure, wildcards, and what erasure forbids.

    Intermediate to Advanced9 cards · 5 qnot started

  • Java lambdas and functional interfaces: passing behaviour as an argument, the four core interfaces, method references and captured variables.

    Intermediate to Advanced9 cards · 5 qnot started

  • Java streams: pipelines over a source, lazy evaluation, map and flatMap, collectors, single use, and when parallel streams pay.

    Intermediate to Advanced10 cards · 6 qnot started

  • Java Optional: a return type that puts possible absence in the signature, how to unwrap it, and where it does not belong.

    Intermediate to Advanced8 cards · 5 qnot started