Skip to content

Instantly share code, notes, and snippets.

@duke13137
Last active December 6, 2025 05:36
Show Gist options
  • Select an option

  • Save duke13137/e5a18174d2cf50a340dd22fd54dbc1b7 to your computer and use it in GitHub Desktop.

Select an option

Save duke13137/e5a18174d2cf50a340dd22fd54dbc1b7 to your computer and use it in GitHub Desktop.
Interview questions

Coding

Java

  • Java is an OOP language: class/object with lambda (functional programmig Java 8+).
  • Encapslation: private, protected, public, final (Immutability) -object identity vs. state, == vs. equals()/hash()
  • Inherience: abstract class vs. final class
    • Template pattern
  • Polymorphism: program to interface
    • Decorator pattern (composition)
    • Visiter pattern (double dispath)
  • Lambda
  • Exceptions
  • java.util.collection:
    • Collection, Iterable for (var : iterator) {}
    • List (ArrayList vs. LinkedList), (Hash vs. Tree) Set/Map
    • When to use Collections.unmodifiableList/Set/Map() vs. java.util.concurrent.ConcurrentHashMap
  • Books

OOP principals:

  • seperate interface from implemenation.
  • program to interface (as type of method parameters)
  • prefer composition/delegation to inheritance
    • patterns: Strategy (interface polymorphsim) vs. Template method (inheritance)
  • avoid mutable state: final fields, record class (Java 17+)

Frameworks

CDI and MVC

  • Spring starts here book
  • Quarkus workshop

SQL and ORM

System Design

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment