Generated by All in One SEO v5.0.0.1, this is an llms.txt file, used by LLMs to index the site. # Java-HandsOn Learn Java in a easy way ## Sitemaps - [XML Sitemap](https://javahandson.com/sitemap.xml): Contains all public & indexable URLs for this website. ## Pages - [Home](https://javahandson.com/) - Recent posts Java Interview Questions - Introduction to Java interview questions- Introduction to Java interview questions- Introduction to Java interview questions- Introduction to Java interview questions- Introduction to Java interview questions- Introduction to Java interview questions- Introduction to Java interview questions- Introduction to Java interview questions Spring Interview Questions - Introduction to - [privacy](https://javahandson.com/privacy-page/) - [About](https://javahandson.com/about/) - [contact](https://javahandson.com/contact-us/) - [WORK WITH ME](https://javahandson.com/work-with-me/) - [JUNIT](https://javahandson.com/junit/) - [HIBERNATE](https://javahandson.com/hibernate/) - [SPRING BOOT](https://javahandson.com/spring-boot/) - [Core Java](https://javahandson.com/core-java/) - Java Tutorial Java Introduction Objected Oriented Concepts Control Statements Arrays Strings Exception Handling Collections Input Output System - [Base64 encoder decoder](https://javahandson.com/base64/) - [Unix timestamp converter](https://javahandson.com/timestamp-converter/) - [MCP Client Config Generator & Validator](https://javahandson.com/mcp-config-generator/) - [Tools](https://javahandson.com/tools/) - [application.properties ↔ application.yml Converter](https://javahandson.com/properties-to-yaml/) - [JSON Formatter & Validator](https://javahandson.com/json-formatter/) - [Latest Updates](https://javahandson.com/latest-updates/) - Stay updated with the latest releases, features, improvements, and important developments across Java, Spring, Spring Boot, Hibernate, Maven, Git, Claude, ChatGPT, System Design, DSA, and other software development technologies. This page brings together concise updates on new versions, framework enhancements, developer tools, AI capabilities, best practices, and emerging trends, helping developers quickly understand what’s new - [Get spring interview book](https://javahandson.com/get-spring-interview-book/) - Spring Framework Interview Questions & Answers 205 must-know questions with in-depth answers · Core Spring, IoC/DI, Spring MVC, AOP, Security & Data JPA · beginner to expert. Pick your local Amazon store below. 🇮🇳 India The paperback isn't available on Amazon.in yet — the Kindle edition is available worldwide, including India. Get Kindle Edition → - [Get real developer book](https://javahandson.com/get-real-developer-book/) - The Real Developer — Staying Good at Code in the Age of AI How to stay sharp, employable, and genuinely good at building software while AI reshapes the craft. Pick your local Amazon store below. 🇮🇳 India The paperback isn't available on Amazon.in yet — the Kindle edition is available worldwide, including India. Get Kindle - [DSA](https://javahandson.com/dsa/) - Master data structures and algorithms in Java through this beginner-friendly series built around classic LeetCode-style problems. Each article walks you from the obvious brute-force solution to the optimized approach interviewers actually want, so you learn the reasoning, not just the answer. Every problem includes clean Java code, step-by-step dry runs, complexity comparisons, and hand-drawn diagrams - [Get Claude code java book](https://javahandson.com/get-claude-code-book/) - Claude Code — The Complete Guide 600+ pages · 24 chapters · A hands-on guide to agentic AI development workflows with Claude Code. Pick your local Amazon store below. 🇮🇳 India The paperback isn't available on Amazon.in yet — the Kindle edition is available worldwide, including India. Get Kindle Edition → Paperback & Kindle by - [Get Java 25 book](https://javahandson.com/get-java-25-book/) - Java 25 — The Complete Guide 500+ pages · 22 chapters · hands-on Java 25 with runnable code and working examples. Pick your local Amazon store below. 🇮🇳 India The paperback isn't available on Amazon.in yet — the Kindle edition is available worldwide, including India. Get Kindle Edition → Paperback & Kindle by country 🇺🇸 - [AI Tools](https://javahandson.com/ai-tools/) - The world of software development is changing fast—and AI is at the center of it. In this section, we explore the AI tools that are transforming how Java developers write code, debug issues, design systems, and learn faster. You will learn: What AI tools are and how they work under the hood How to use - [System Design](https://javahandson.com/system-design/) - System Design is the process of designing the architecture, components, and interactions of a software system to meet functional and non-functional requirements such as scalability, reliability, performance, and maintainability. It involves making high-level decisions about system structure, data flow, databases, APIs, and infrastructure to ensure the application can efficiently handle current and future user demands. - [Java 25 ↑](https://javahandson.com/java-25/) - Java 25 (released September 16, 2025) is a Long-Term Support (LTS) version of the JDK, bringing 18 new JEPs and enhancements. It focuses on developer productivity (e.g., compact source files/instance main methods) and cleaner syntax. It also boosts performance via features like compact object headers, ahead-of-time method profiling, and improvements to the garbage collector. Java 25 further - [Interview](https://javahandson.com/interview/) - This page is designed to help developers prepare for technical interviews with a strong focus on Java, Spring Framework, and related technologies. Whether you are just starting your career or have several years of experience, you will find carefully curated questions and detailed answers that cover both fundamentals and advanced concepts. We aim to organize - [Spring](https://javahandson.com/spring/) - Spring is one of the most widely used Java frameworks to develop Java enterprise edition applications. Spring reduces the boilerplate code and helps us to focus on business logic. It provides many important features like dependency injection and inversion of control to make things easier for developers. In this section, we will learn the Spring - [java 8](https://javahandson.com/java-8/) - JAVA 8 is one of the major releases of Java. Till version 7, Java was just an Object-oriented programming language but in version 8 the concept of functional programming was introduced. With the world moving towards Big Data and Machine learning Java realized the need to focus on functional programming hence they have introduced concepts - [JAVA](https://javahandson.com/java/) - Java is one of the most popular and widely used programming languages. The TIOBE Programming Community ranks Java in the top 3 popular programming languages. Java is the best when we have to create large-scale enterprise applications this is the reason almost 90 percent of the top 500 Fortune companies use Java. This section will ## sliders - [The Best Online Learning
Platform for Java](https://javahandson.com/sliders/the-best-onlinelearning-platform/) - [Communicate your doubts](https://javahandson.com/sliders/get-educated-onlinefrom-your-home/) ## Courses - [RabbitMQ Exchanges and Queues Explained, Plus the Real Kafka vs RabbitMQ Trade-offs](https://javahandson.com/rabbitmq-exchanges-and-queues) - RabbitMQ exchanges and queues explained simply, with exchange types, Spring Boot code, and the real Kafka vs RabbitMQ trade-offs. - [Creating Threads in Java: Thread Class vs Runnable Interface](https://javahandson.com/creating-threads-in-java) - Learn creating threads in Java two ways — extending Thread vs implementing Runnable. Full examples, a comparison table, lambdas, and the start() vs run() trap. - [Thread Life Cycle in Java: States and Transitions Explained](https://javahandson.com/thread-life-cycle-in-java) - A deep dive into the thread life cycle in Java. Understand all six thread states, every transition between them, getState(), and the RUNNABLE vs running myth. - [Collections Utility Class in Java: sort, binarySearch, and unmodifiable](https://javahandson.com/collections-utility-class-in-java) - Learn the Collections utility class in Java — sort, binarySearch, unmodifiable, min, max, shuffle and more, with simple examples and interview tips. - [Sorting Collections in Java: Collections.sort & Custom Orders](https://javahandson.com/sorting-collections-in-java) - Learn sorting collections in Java the easy way. Master Collections.sort, Comparable, Comparator, multi-field sorts, reversing, and null handling with examples. - [Multithreading in Java: Threads and Concurrency Explained](https://javahandson.com/multithreading-in-java) - Introduction to multithreading in Java. Understand what a thread is, process vs thread, concurrency vs parallelism, the main thread, and where threads are used. - [Kafka Deep Dive: Partitions, Consumer Groups, Offsets, and Ordering Guarantees](https://javahandson.com/kafka-deep-dive) - A beginner-friendly Kafka deep dive into partitions, consumer groups, offsets, and ordering guarantees — with diagrams and interview insights for developers. - [Finding and Matching in Java 8](https://javahandson.com/finding-and-matching-in-java-8) - A guide to finding and matching in Java 8 — findFirst, findAny, anyMatch, allMatch, and noneMatch — with short-circuiting, empty-stream rules, and examples. - [Longest Substring Without Repeating Characters in Java DSA](https://javahandson.com/longest-substring-without-repeating-characters) - Solve Longest Substring Without Repeating Characters in Java with a clear sliding window. Step-by-step dry runs for brute, HashSet, and index-array approaches. - [Longest Repeating Character Replacement in Java DSA](https://javahandson.com/longest-repeating-character-replacement) - Solve Longest Repeating Character Replacement in Java DSA with a clear sliding window. Full step-by-step dry runs, simple pseudocode, and easy Java code. - [Comparable vs Comparator in Java: Sorting Objects the Right Way](https://javahandson.com/comparable-vs-comparator-in-java) - Comparable vs Comparator in Java made simple. Learn compareTo vs compare, when to use each, and how to sort custom objects with clear runnable examples. - [ConcurrentModificationException in Java: Causes and Fixes](https://javahandson.com/concurrentmodificationexception-in-java) - ConcurrentModificationException in Java explained simply. Learn why it happens, how the modCount check works, and five clean fixes with code examples. - [Reduce Method in Java 8 Streams – identity, accumulator and combiner](https://javahandson.com/reduce-method-in-java-8-streams) - In this article we will try to understand what is a reduce method in Java 8 streams. We will also learn about different variants of reduce methods with examples. - [Iterator and ListIterator in Java: Fail-Fast vs Fail-Safe](https://javahandson.com/iterator-and-listiterator-in-java) - Learn how Iterator and ListIterator in Java work, the difference between fail-fast and fail-safe iterators, and how to avoid ConcurrentModificationException. - [flatmap in Java 8 streams](https://javahandson.com/flatmap-in-java-8-streams) - In this article, we will try to understand what is a flatmap in Java 8 streams with examples. Here we will also learn about different flatMap methods - [Java Security Updates Are Going Monthly: What the New CSPU Cadence Means for Your JDK](https://javahandson.com/java-security-updates) - Java security updates are shifting to a monthly CSPU cadence. Learn what JDK 26.0.2.1 means, why Oracle made the change, and how to patch safely. - [Spring Security Interview Questions – Architecture and Authentication](https://javahandson.com/spring-security-interview-questions) - Spring Security interview questions on the filter chain, SecurityFilterChain, AuthenticationManager, UserDetailsService and BCrypt, with code answers. - [Spring Security JWT Interview Questions: OAuth2 & Method Security](https://javahandson.com/spring-security-jwt-interview-questions) - Spring Security JWT interview questions with answers: OAuth2 Authorization Code flow, @PreAuthorize, CSRF, CORS, refresh tokens and session policy. - [Spring MVC Exception Handling Interview Questions](https://javahandson.com/spring-mvc-exception-handling-interview-questions-validation-controlleradvice-and-advanced-features) - Master Spring MVC exception handling with the most-asked interview questions on @ControllerAdvice, @ExceptionHandler, and validation — answered with code. - [Spring Data JPA Interview Questions – Repositories, Queries and Mappings](https://javahandson.com/spring-data-jpa-interview-questions) - Master Spring Data JPA interview questions: repositories, derived queries, @Query, mappings, fetch types, cascade, projections, and @EntityGraph with code. - [mapping in Java 8 streams](https://javahandson.com/mapping-in-java-8-streams) - Learn mapping in Java 8 streams with clear examples of map, mapToInt, mapToLong and mapToDouble, plus pitfalls and interview questions. - [Scaling and Data Basics](https://javahandson.com/scaling-and-data-basics) - Scaling and data basics explained: scalability, load balancing, caching, replication, and SQL vs NoSQL — a Week 1 system design roadmap with six deep dives. - [TreeSet in Java: Sorting, Comparators & NavigableSet Guide](https://javahandson.com/treeset-in-java) - TreeSet in Java keeps elements sorted automatically. Learn how sorting, comparators, and NavigableSet methods work — with practical code examples. - [Spring MVC Interview Questions - Architecture, DispatcherServlet and Request Handling](https://javahandson.com/spring-mvc-interview-questions-architecture-dispatcherservlet-and-request-handling) - Master spring mvc interview questions: DispatcherServlet, HandlerMapping, ViewResolver, CORS, content negotiation — 15 deep Q&A with code - [Abstract Class in Java: When and Why to Use It (Examples)](https://javahandson.com/abstract-class-in-java-when-and-why-to-use-it) - Learn what an abstract class in Java is, when to use it versus an interface, and why it matters — with clear, runnable code examples. - [Claude Fable 5 Explained: What It Is and Why It Matters](https://javahandson.com/claude-fable-5) - Claude Fable 5 is Anthropic's new Mythos-tier model. Here's what it is, how it differs from Opus, and what it means for developers. - [Java 25 Generational Shenandoah GC (JEP 521): Lower Pauses](https://javahandson.com/jep-521-generational-shenandoah-garbage-collector-in-java-25-explained) - Java 25 makes Shenandoah generational. See how generational Shenandoah (JEP 521) cuts pause times and memory overhead, when to use it, and how to enable it. - [Top Spring AOP Interview Questions with Answers + Examples](https://javahandson.com/spring-aop-interview-questions-core-concepts-and-advice-types) - These Spring AOP interview questions cover pointcuts, advice types, proxies, and weaving — each answered clearly with code examples to prep you fast. - [Java Removes 32-bit x86 Support: What It Means for You](https://javahandson.com/java-removes-32-bit-x86-support) - Java is removing 32-bit x86 support. Find out which JDK version drops it, why Oracle made the call, and whether your builds or deployments are affected. - [JEP 519: Compact Object Headers in Java 25 — Less Heap](https://javahandson.com/jep-519-compact-object-headers-in-java-25-from-experimental-to-production) - Java 25 compact object headers (JEP 519) shrink headers from 12–16 bytes to 8, cutting heap use and improving cache locality. See what changes and how to enable it. - [JEP 513: Flexible Constructor Bodies — Code Before super()](https://javahandson.com/jep-513-java-25-flexible-constructor-bodies-explained) - Java 25 flexible constructor bodies let you validate arguments before calling super() or this(). See how JEP 513 works, with before/after code examples. - [JEP 512: Java 25 Without public static void main?](https://javahandson.com/jep-512-explained-compact-source-files-and-simpler-java-programs) - JEP 512 lets you run a Java 25 program without a class, static, or public static void main. See compact source files and instance main() with runnable examples. - [Introduction to Streams in Java 8: Creating Streams from Values, Arrays and Collections](https://javahandson.com/introduction-to-streams-in-java) - An introduction to streams in Java 8 : Create a stream with Stream.of, iterate, generate, Arrays.stream and collections, plus pitfalls and interview questions. - [Filtering in Streams](https://javahandson.com/filtering-in-streams) - In this article, we will look at how to achieve filtering in streams with proper examples. - [Sorting Streams in Java 8 – sorted, Comparator.comparing, thenComparing, reversed](https://javahandson.com/sorting-streams-in-java-8) - Learn sorting streams in Java 8 with sorted, Comparator.comparing, thenComparing and reversed. Simple examples for sorting objects, tie-breakers and nulls. - [Stack in Java: Why ArrayDeque Replaced It](https://javahandson.com/stack-in-java) - Learn how a Stack in Java works and why the docs now recommend ArrayDeque. See the design flaws, a speed comparison, and an easy migration with code. - [Type Casting in Java](https://javahandson.com/type-casting-in-java) - Learn about type casting in Java – widening, narrowing, object casting, generalization, specialization, and cloning with examples. - [Database Query Optimization in System Design: Indexing, Query Tuning, and Connection Pooling](https://javahandson.com/database-query-optimization) - Database query optimization in System Design - how indexing, query tuning, and connection pooling make your data layer fast, with diagrams and interview tips. - [Sliding Window Maximum Average Subarray in Java DSA](https://javahandson.com/sliding-window-maximum-average-subarray-in-java-dsa) - Solve Sliding Window Maximum Average Subarray in Java DSA in 3 ways — brute force, prefix sum, and sliding window — with step-by-step dry runs and clean code. - [ArrayDeque in Java: The Better Stack and Queue](https://javahandson.com/arraydeque-in-java) - Learn ArrayDeque in Java — the faster, cleaner stack and queue. See core methods, how the circular array works, and when to pick it over Stack and LinkedList. - [Function Composition in Java 8: andThen, compose, and Predicate Chaining](https://javahandson.com/function-composition-in-java-8) - Learn function composition in Java 8 with andThen, compose, and Predicate chaining. Simple examples, pipelines, common mistakes, and interview questions - [PriorityQueue in Java: Heap Internals & Comparators](https://javahandson.com/priorityqueue-in-java) - Learn how PriorityQueue in Java works under the hood — the min-heap, array storage, natural ordering, and custom comparators — with clear, runnable examples. - [Passing code as a parameter in Java 8](https://javahandson.com/passing-code-as-a-parameter) - We will learn the use of Passing code as a parameter in Java 8. We will slightly move from the verbosity issue to the anonymous class to lambda expressions - [Load Balancing and Types of Load Balancers Explained](https://javahandson.com/types-of-load-balancers) - Load balancing and the main types of load balancers explained: server-side, DNS, client-side, plus L4 vs L7, algorithms, and sticky sessions. - [Method reference in Java 8](https://javahandson.com/method-reference-in-java-8) - Method reference in Java lets you reuse an existing method wherever a lambda would go. Learn the :: operator, all four reference types, and when to pick each one. 1. Introduction1.1 What This Article Covers2. What Is a Method Reference?2.1 The Problem It Solves2.2 From Lambda to Method Reference2.3 The :: Syntax2.4 It Is Still - [Queue and Deque in Java: Interfaces and Core Methods (A Beginner's Guide)](https://javahandson.com/queue-and-deque-in-java) - Learn Queue and Deque in Java the easy way. Understand FIFO, core methods like offer, poll, and peek, two-ended Deque access, and when to use ArrayDeque. - [URL Shortener System Design: How to Build a Scalable Short-Link Service](https://javahandson.com/url-shortener-system-design) - URL shortener system design explained end to end: estimation, Base62 short codes, read and write paths, caching, and sharding for a scalable short-link service. - [Wrapper Classes and Autoboxing in Java: A Beginner's Guide](https://javahandson.com/wrapper-classes-and-autoboxing-in-java) - Wrapper classes and autoboxing in Java made simple — the 8 wrappers, boxing vs unboxing, the Integer cache == trap, null pitfalls, and interview Q&A. - [Type Conversion and Casting in Java (Primitives): A Beginner's Guide](https://javahandson.com/type-conversion-and-casting-in-java) - Learn type conversion and casting in Java for primitives. See widening vs narrowing, when Java auto-converts, when you need a cast, and the data traps to avoid. - [Variables and Constants in Java](https://javahandson.com/variables-and-constants-in-java) - Learn how variables and constants in Java work: declaration, initialization, the three variable types, scope, the final keyword, and the naming rules every beginner should know. - [Predefined Functional interfaces with 2 input arguments](https://javahandson.com/predefined-functional-interfaces-with-2-input-arguments) - In this article, we will learn about the most commonly used predefined functional interfaces with 2 input arguments with basic examples. - [Longest Consecutive Sequence in Java DSA: Brute Force, Sorting, and the HashSet Trick](https://javahandson.com/longest-consecutive-sequence-in-java-dsa) - Solve Longest Consecutive Sequence in Java DSA three ways — brute force, sorting, and the O(n) HashSet trick — with full step-by-step dry runs for beginners. - [EnumMap and IdentityHashMap in Java: Two Special Maps Worth Knowing](https://javahandson.com/enummap-and-identityhashmap-in-java) - EnumMap and IdentityHashMap in Java explained simply. Learn how each stores keys, when to use them, and the bugs IdentityHashMap can cause. With examples. - [Predefined Functional interfaces](https://javahandson.com/predefined-functional-interfaces) - In this article, we will learn about the most commonly used predefined functional interfaces with basic examples. - [Consistent Hashing in System Design: How to Draw the Ring and Explain Rebalancing](https://javahandson.com/consistent-hashing-in-system-design) - Consistent hashing in System Design explained simply — learn to draw the hash ring, map keys to nodes, and handle rebalancing when servers join or leave. - [Top K Frequent Elements in Java DSA: HashMap, Heap, and Bucket Sort](https://javahandson.com/top-k-frequent-elements-in-java-dsa) - Solve Top K Frequent Elements in Java DSA three ways — HashMap sort, min-heap, and O(n) bucket sort — with beginner-friendly dry runs and clean code. - [Custom Functional Interface in Java: @FunctionalInterface Explained](https://javahandson.com/custom-functional-interface) - Learn how to write a custom functional interface in Java, what @FunctionalInterface really does, and when to use it instead of Function or Predicate. - [HashMap vs Hashtable vs ConcurrentHashMap in Java: A Beginner's Guide](https://javahandson.com/hashmap-vs-hashtable-vs-concurrenthashmap) - HashMap vs Hashtable vs ConcurrentHashMap in Java explained simply. Learn thread safety, null rules, locking, performance, and which Java map to pick and when. - [TreeMap in Java Explained: Sorting, NavigableMap & SortedMap](https://javahandson.com/treemap-in-java) - TreeMap in Java keeps keys sorted using a red-black tree. Learn SortedMap, NavigableMap, floor/ceiling methods, custom comparators, and when to use it. - [Lambda expression in Java 8](https://javahandson.com/lambda-expression-in-java-8) - In this article, we will learn what is a lambda expression in Java 8. We will also learn how to make use of lambda expressions with proper examples. - [Sharding and Partitioning Strategies in System Design: Range, Hash, and Directory Explained](https://javahandson.com/sharding-and-partitioning-strategies) - Sharding and partitioning strategies in system design explained simply — compare range, hash, and directory sharding, pick the right shard key, and avoid hotspots. - [LinkedHashMap in Java: Access Order & Building an LRU Cache](https://javahandson.com/linkedhashmap-in-java) - Learn LinkedHashMap in Java with simple examples. See how insertion order and access order work, then build a working LRU cache in just a few lines. - [HashMap vs LinkedHashMap vs TreeMap in Java (A Beginner's Guide)](https://javahandson.com/hashmap-linkedhashmap-treemap) - HashMap vs LinkedHashMap vs TreeMap in java explained simply. Compare order, speed, and null handling, and learn exactly when to use each Java Map class. - [Group Anagrams in Java DSA: Sorting Key and Count Key, Explained Step by Step](https://javahandson.com/group-anagrams-in-java-dsa) - Learn Group Anagrams in Java DSA with two clear approaches — a sort key and a faster count key. Step-by-step dry runs, beginner-friendly code, and complexity. - [StringBuilder in Java](https://javahandson.com/stringbuilder-in-java) - Explore StringBuilder in Java - its features, constructors, methods, and efficient memory management for better performance. - [HashMap in Java: Map Interface, Buckets & Hashing Explained](https://javahandson.com/hashmap-in-java) - Learn how HashMap in Java works — the Map interface, key-value pairs, buckets, hashing, collisions, and treeification since Java 8. A clear beginner's guide. - [LinkedList in Java Explained: ArrayList vs LinkedList (Internals)](https://javahandson.com/linkedlist-in-java) - ArrayList vs LinkedList in Java, made simple. See doubly linked list internals and why Big-O theory often loses to real benchmarks. - [StringBuffer in Java](https://javahandson.com/stringbuffer-in-java) - Explore StringBuffer in Java: Key features, constructors, methods, and memory management for efficient, thread-safe string manipulation. - [String immutability in Java](https://javahandson.com/string-immutability-in-java) - Discover the concept of string immutability in Java, including how strings are stored in the String Pool, ways to create strings and enhancing performance. - [String in Java](https://javahandson.com/string-in-java) - In this article, we will learn what is a String in Java and different ways of creating a String and its methods. We will also learn what is the difference between String Literal and String Object. - [String comparison in Java](https://javahandson.com/string-comparison-in-java) - Learn about string comparison in Java using equals(), equalsIgnoreCase(), ==, compareTo(), and compareToIgnoreCase(). Master their differences and usage. - [HashSet vs LinkedHashSet: Ordering Without Sacrificing Speed](https://javahandson.com/hashset-vs-linkedhashset) - HashSet vs LinkedHashSet compared — insertion order, memory overhead, and why LinkedHashSet often iterates faster thanks to cache locality. - [HashSet in Java: How Sets Work (Beginner's Guide)](https://javahandson.com/hashset-in-java) - Learn how HashSet in Java works internally — uniqueness, equals() and hashCode(), buckets, O(1) performance, and thread safety. A clear beginner's guide. - [ArrayList in Java: List Interface Core Concepts & Internals (Beginner's Guide)](https://javahandson.com/arraylist-in-java-list-interface) - Learn how ArrayList in Java works under the hood — the List interface, index access, dynamic array resizing, and why get() is O(1) but middle inserts are O(n). - [Introduction to Collections Framework in Java](https://javahandson.com/introduction-to-collections-framework-in-java) - Learn Introduction to Collections Framework in Java with examples, hierarchy, benefits, and why collections are better than arrays. - [Database Indexing in MySQL Explained: B-Tree, Primary, Secondary, Composite Indexes and Selectivity](https://javahandson.com/database-indexing-in-mysql) - A beginner-friendly guide to database indexing in MySQL. Understand B-tree structure, primary, secondary and composite indexes, and how selectivity decides if an index helps. - [Exception Rules in Java](https://javahandson.com/exception-rules-in-java) - Understand the key exception rules in Java including how checked and unchecked exceptions are handled and the impact of inheritance and polymorphism on exception handling - [Custom and Chained exceptions in Java](https://javahandson.com/custom-and-chained-exceptions-in-java) - Learn how to create and use custom and chained exceptions in Java to improve error handling and debugging. This guide covers how to implement custom exception classes and chaining exceptions for better traceability. - [Throwing Exceptions in Java](https://javahandson.com/throwing-exceptions-in-java) - In this article, we will learn about throwing exceptions in Java using the throw and throws keyword with proper examples. - [try, catch and finally, blocks](https://javahandson.com/try-catch-and-finally-blocks) - In this article, we will learn what try, catch and finally, blocks are in Java and how they are used in exception-handling mechanisms with proper examples. - [Introduction to Exception Handling in Java](https://javahandson.com/introduction-to-exception-handling-in-java) - In this article, we will introduce Exception Handling in Java. We will also learn about the types of exceptions and the errors. - [Consistency Models in System Design: Strong, Eventual, Causal, and Read-Your-Writes](https://javahandson.com/consistency-models-in-system-design) - Consistency models in system design explained simply: strong, eventual, causal, and read-your-writes. Learn what each promises, its cost, and when to use it. - [Literals in Java: Types, Rules, and the Traps Nobody Warns You About](https://javahandson.com/literals-in-java) - Literals in Java explained — every type (int, long, float, char, String) plus the octal, overflow, and == traps that silently break real code, with examples. - [Keywords and Identifiers in Java: A Simple Beginner's Guide](https://javahandson.com/keywords-and-identifiers-in-java) - Learn keywords and identifiers in Java the easy way. See the full keyword list, naming rules, camelCase vs PascalCase conventions, and common beginner mistakes. - [JDK 11 installation on Windows](https://javahandson.com/jdk-11-installation-on-windows) - JDK 11 installation on Windows, step by step: download Oracle or free OpenJDK, set JAVA_HOME and Path, fix the "java is not recognized" error, and verify. - [Structure of a Java program](https://javahandson.com/structure-of-a-java-program) - The structure of a Java program explained rule by rule: package/import order, the one-public-class rule, the main method, static init, and common mistakes. - [Java basics for beginners](https://javahandson.com/java-basics-for-beginners) - Java basics for beginners: what Java is, JDK vs JRE vs JVM, how code runs, the 3 editions (SE, EE, ME), 10 core features, and modern LTS Java. - [Module Import Declarations Java 25 – JEP 511](https://javahandson.com/module-import-declarations-java-25) - Module Import Declarations Java 25 explained via JEP 511. Learn how import module simplifies imports and improve readability in modular Java code. - [JFR CPU-Time Profiling in Java 25](https://javahandson.com/jfr-cpu-time-profiling-in-java-25) - JFR CPU-Time Profiling in Java 25 reveals true CPU usage with CPU-time sampling and flame graphs, making production profiling accurate and reliable. - [Vector API in Java 25](https://javahandson.com/vector-api-in-java-25) - Vector API in Java 25 explained with examples. Learn SIMD, vector species, loopBound, masking, and when to use vector computation for high performance. - [Primitive patterns in Java 25](https://javahandson.com/primitive-patterns-in-java-25) - Explore primitive patterns in Java 25 and learn how they enhance instanceof, switch, and nested patterns with safe conversions and cleaner, consistent code. - [StableValue in Java 25](https://javahandson.com/stablevalue-in-java-25) - In this article, we’ll explore everything about StableValue in Java 25 - from what it is and why it exists, to how it works internally, its syntax, performance behavior, and how we can migrate existing lazy-initialization patterns to this modern, efficient API. By the end, we’ll clearly understand how StableValue simplifies concurrent programming and paves - [JEP 470 in Java 25](https://javahandson.com/jep-470-in-java-25) - Explore JEP 470 in Java 25 - native PEM APIs that replace BouncyCastle parsing, simplify key handling, and enhance Java’s built-in cryptographic security. - [JFR Cooperative Sampling in Java 25 (JEP 518)](https://javahandson.com/jfr-cooperative-sampling-in-java-25-jep-518) - JFR Cooperative Sampling in Java 25 improves profiling stability by safely collecting stack traces at safepoints, reducing crashes and safepoint bias. - [Valid Anagram in Java DSA: Sorting, HashMaps, and the Count Array Trick](https://javahandson.com/valid-anagram-in-java-dsa) - Solve Valid Anagram in Java DSA three ways — sorting, a HashMap counter, and the O(1) count array. Full step-by-step dry runs for beginners. - [Packages in Java](https://javahandson.com/packages-in-java) - Struggling with Packages in Java? Learn with simple examples, clear explanations, and real-world usage in this complete beginner's guide. - [CAP Theorem and PACELC in System Design: How to Actually Apply Them](https://javahandson.com/cap-theorem-and-pacelc) - Learn the CAP theorem and PACELC the practical way. Worked examples, database classifications, and quorum tuning so you can apply them, not just recite them. - [Inheritance vs Composition in Java: A Practical Guide](https://javahandson.com/advanced-inheritance-in-java-modifiers-object-composition) - Inheritance vs composition in Java explained with examples: what extends really exposes, final and sealed classes, and when to delegate instead. - [Understanding Inheritance in Java: Syntax, Types, and the Diamond Problem](https://javahandson.com/understanding-inheritance-in-java) - Understanding inheritance in Java with syntax, types, constructor chaining, super keyword, and the diamond problem explained with simple examples. - [Class Members in Java](https://javahandson.com/class-members-in-java) - Learn class members in Java with simple explanations and examples. Understand instance variables, methods, constructors, static members, and nested classes in an easy way. - [Product of Array Except Self in Java DSA: Two Clean Passes, No Division](https://javahandson.com/product-of-array-except-self-in-java-dsa) - Solve Product of Array Except Self in Java DSA without division. Brute force, prefix/suffix arrays, and the O(1)-space two-pass sweep, each with a full dry run. - [Polymorphism in Java](https://javahandson.com/polymorphism-in-java) - Understand polymorphism in Java with examples. Learn method overloading, overriding, dynamic dispatch, and how polymorphism helps write flexible and reusable code. - [Abstraction in Java](https://javahandson.com/abstraction-in-java) - Understand abstraction in Java with easy examples. Learn abstract classes, interfaces, benefits & best practices to write clean, flexible code. - [Advanced Java method concepts](https://javahandson.com/advanced-java-method-concepts) - Advanced Java method concepts take you past the basics of writing a method. Here we cover recursion, varargs, access modifiers, method scope, pass-by-value, and the habits that keep your methods clean. 1. Introduction1.1 What This Article Covers2. Recursion in Java Methods2.1 What Recursion Really Means2.2 The Two Parts Every Recursive Method Needs2.3 Factorial, Step by - [Methods in Java](https://javahandson.com/methods-in-java) - Explore basics about methods in Java — from syntax and types to overloading, overriding, static, final, abstract, and synchronized methods. - [Constructors in Java](https://javahandson.com/constructors-in-java) - Learn constructors in Java the easy way: default, parameterized and copy constructors, overloading, chaining with this() and super(), initialization order, and private constructors. 1. Introduction1.1 What This Article Covers2. What Is a Constructor?2.1 The Core Idea2.2 Constructor Versus Method2.3 Why Constructors Matter3. Types of Constructors in Java3.1 The No-Argument Constructor3.2 The Compiler's Default Constructor3.3 The - [Class Types in Java](https://javahandson.com/class-types-in-java) - Learn the class types in Java with clear examples: concrete, abstract, interface, nested, inner, local, anonymous, final, enum, record, and sealed classes. A friendly beginner guide. 1. Introduction1.1 What This Article Covers2. What a Class Type Really Means2.1 A Class Is a Blueprint2.2 Why Java Needs More Than One Kind2.3 The Five Main Types at - [HashMap Doubts Explained in Java: Keys, Retrieval, Equality, Mutability, Nulls, and Collisions](https://javahandson.com/hashmap-doubts-explained-in-java) - HashMap Doubts Explained in Java with clear answers on keys, hashing, equals(), hashCode(), nulls, collisions, retrieval, resizing, and custom keys. - [HashMap Internal Working in Java: A Beginner-Friendly Deep Dive](https://javahandson.com/hashmap-internal-working-in-java-a-beginner-friendly-deep-dive) - Learn the HashMap internal working in Java in simple words — hashing, buckets, collisions, resizing, and the equals/hashCode contract, with clear examples. - [Merge Sorted Array in Java DSA: From an Extra Array to the Backward Sweep](https://javahandson.com/merge-sorted-array-in-java-dsa) - Learn Merge Sorted Array in Java DSA with three approaches, full step-by-step dry runs, and the in-place backward two-pointer solution interviewers want. - [Nested and Inner Classes in Java: A Complete Beginner's Guide](https://javahandson.com/nested-and-inner-classes-in-java) - Learn nested and inner classes in Java the easy way. Static nested, inner, local, and anonymous classes explained with simple examples and interview tips. - [Move Zeroes in Java DSA: Push Every Zero to the End Without Losing Order](https://javahandson.com/move-zeroes-in-java-dsa) - Learn move zeroes in java DSA three ways, from a helper list to the one-pass two-pointer swap, with full step-by-step dry runs and clean code. - [Enum in Java: A Complete Beginner’s Guide with Examples](https://javahandson.com/enum-in-java) - Learn what an enum in Java is, how to declare one, and how to use fields, constructors, methods, switch, EnumSet, and EnumMap — with clear beginner examples. - [Object Class in Java: toString, equals, hashCode, getClass, and clone](https://javahandson.com/object-class-in-java) - Learn the Object class in Java the easy way. Understand toString, equals, hashCode, getClass, and clone with simple examples, shallow vs deep copy, records, and interview questions. - [SQL vs NoSQL Trade-offs in System design: When to Pick Which, With Examples](https://javahandson.com/sql-vs-nosql-trade-offs-in-system-design) - Understand SQL vs NoSQL trade-offs in System design with clear rules for picking each. Covers ACID, CAP, sharding, and five real scenarios with Spring Boot code examples. - [Database Replication in System Design Explained: Leader-Follower, Sync vs Async, and Read Replicas](https://javahandson.com/database-replication-in-system-design) - Database replication in system design explained - leader-follower, sync vs async, read replicas, replication lag, failover, and how apps route reads and writes. - [Redis Cache Invalidation and Hot Keys: A Deep Dive](https://javahandson.com/redis-cache-invalidation) - Learn Redis cache invalidation and hot key fixes step by step: TTL and eviction, delete-on-write, SCAN, versioned keys, local caching, and stampede defenses. - [Caching Strategies in System Design: Patterns and Eviction Policies](https://javahandson.com/caching-strategies-in-system-design) - Caching strategies in system design explained: cache-aside, write-through and write-behind patterns, plus LRU, LFU and TTL eviction, with clear examples. - [Back-of-the-Envelope Estimation & System Design Basics](https://javahandson.com/back-of-the-envelope-estimation) - Back-of-the-envelope estimation explained for Java developers, with scalability and latency vs throughput basics and code examples. - [Maximum Subarray in Java DSA: From Brute Force to Kadane’s Algorithm](https://javahandson.com/maximum-subarray-in-java-dsa) - Learn Maximum Subarray in Java DSA step by step — from brute force to Kadane's algorithm, with full dry runs on an array and clean, beginner-friendly code. - [Contains Duplicate in Java DSA: From Brute Force to a One-Pass HashSet](https://javahandson.com/contains-duplicate-in-java-dsa) - Solve Contains Duplicate in Java DSA three ways — brute force, sort, and a one-pass HashSet — with full step-by-step dry runs and complexity comparison. - [Best Time to Buy and Sell Stock in Java DSA: From Brute Force to a Single Clean Pass](https://javahandson.com/best-time-to-buy-and-sell-stock-in-java-dsa) - Solve Best Time to Buy and Sell Stock in Java DSA, from a brute-force pair check to a clean one-pass running-minimum trick, with full step-by-step dry runs. - [Two Sum in Java DSA: From Brute Force to the One-Pass HashMap](https://javahandson.com/two-sum-in-java-dsa) - Learn Two Sum in Java DSA step by step, from brute force to the one-pass HashMap. Full dry runs, clean code, and complexity comparison for beginners. - [Container With Most Water in Java DSA: The Two-Pointer Trick That Beats Every Loop](https://javahandson.com/container-with-most-water-in-java-dsa) - Solve Container With Most Water in Java DSA the easy way. Full step-by-step dry runs of the brute force and O(n) two-pointer approaches, with clean code. - [Valid Palindrome in Java DSA: Two Pointers from the Outside In](https://javahandson.com/valid-palindrome-in-java-dsa) - Learn Valid Palindrome in Java DSA step by step. Move from brute force to a clean two-pointer scan with full dry runs, code, and complexity comparisons for interviews. - [Reverse String in Java DSA: Two Pointers That Swap in Place](https://javahandson.com/reverse-string-in-java-dsa) - Reverse String in Java DSA made simple. Learn recursion, an extra-array version, and the optimal in-place two-pointer swap with dry runs and clean code. - [3Sum in Java DSA: From the Triple Loop to the Two-Pointer Sweep](https://javahandson.com/3sum-in-java-dsa) - Learn 3Sum in Java DSA step by step, from a simple brute-force triple loop to the clean sort-and-two-pointer solution, with dry runs and beginner-friendly explanations. - [Interface in Java Explained with Examples](https://javahandson.com/interface-in-java) - Interface in Java explained with simple examples. Learn why interfaces exist, how they work, common mistakes, and real-world use cases in Java. - [Encapsulation in Java: A Beginner-Friendly Guide with Examples](https://javahandson.com/encapsulation-in-java) - Learn encapsulation in Java the easy way. Understand private fields, getters and setters, access modifiers, and see a full working BankAccount example. - [final Keyword in Java: Variables, Methods, and Classes (A Beginner's Guide)](https://javahandson.com/final-keyword-in-java) - Learn the final keyword in Java the easy way. See how final locks variables, methods, and classes, plus final vs finally vs finalize and interview questions. - [static Keyword in Java: Variables, Methods, Blocks and Nested Classes Explained](https://javahandson.com/static-keyword-in-java) - Learn the static keyword in Java with clear examples. Covers static variables, methods, blocks, nested classes, class loading order and interview questions. - [this and super Keywords in Java: A Complete Beginner Guide](https://javahandson.com/this-and-super-keywords-in-java) - Master this and super keywords in Java with clear examples. Fix parameter shadowing, chain constructors, extend overridden methods, and avoid common mistakes. - [Java 8 Summarizing Methods with Examples](https://javahandson.com/java-8-summarizing-methods) - Learn Java 8 Summarizing Methods with clear examples. Understand summarizingInt(), summarizingLong(), and IntSummaryStatistics in streams. - [Partitioning in Java 8](https://javahandson.com/partitioning-in-java-8) - In this article, we will understand what is Partitioning in Java 8. We will also learn about different variants of partitioning methods with examples. - [Summing method in Collectors API](https://javahandson.com/summing-method-in-collectors-api) - In this article, we will understand the summing method in the Collectors API. We will also learn about different variants of this method with examples. - [Principles of Object-oriented Programming](https://javahandson.com/principles-of-object-oriented-programming) - In this article, we will learn about the principles of object-oriented programming with some basic examples. - [Types of data members](https://javahandson.com/types-of-data-members) - In this article, we are going to learn about the types of data members in Java like instance and static members with proper examples. - [Access specifiers in Java](https://javahandson.com/access-specifiers-in-java) - Learn about Access Specifiers in Java - Private, Public, Protected, and Default. Understand their usage, differences, and best practices with examples. - [Classes and Objects in Java](https://javahandson.com/classes-and-objects-in-java) - Learn Classes and Objects in Java with simple explanations, examples, memory concepts, and best practices for beginners. - [break and continue statement in Java](https://javahandson.com/break-and-continue-statement-in-java) - In this article, we will learn the break and continue statement in Java with simple, hands-on examples. - [do while and while Loop in Java: Syntax, Examples, and Differences](https://javahandson.com/dowhile-loop) - Learn the do while and while loop in Java with simple examples. See the syntax, how each loop runs, and the one key difference between the two. - [for loop and nested for loop in Java](https://javahandson.com/for-loop-and-nested-for-loop-in-java) - In this article, we will learn the for loop and nested for loop in Java with simple, hands-on examples. - [Conditional Statements in Java: if, else-if, Nested if, switch and Ternary](https://javahandson.com/conditional-statements-in-java) - Conditional statements in Java explained for beginners. Learn if, if-else, the else-if ladder, nested if, and the ternary operator with clear examples. - [Ternary Operator in Java](https://javahandson.com/ternary-operator-in-java) - In this article, we will learn what is a ternary operator in Java with proper examples. - [Bitwise Operators in Java](https://javahandson.com/bitwise-operators-in-java) - In this article, we will learn what Bitwise operators are and what are different Bitwise operators in Java with proper examples. - [Unary Operators in Java](https://javahandson.com/unary-operators-in-java) - In this article, we will learn what is an unary operator and what are different unary operators in Java with proper examples. - [Operators in Java](https://javahandson.com/operators-in-java) - In this article, we will learn what is an Operator in Java and the types of Operators in Java with proper examples. - [var in Java: Local Variable Type Inference (A Beginner's Guide)](https://javahandson.com/var-in-java) - Learn how var in Java works, where you can and cannot use it, and when it makes code cleaner. A beginner-friendly guide to local variable type inference. - [Data types in Java with examples](https://javahandson.com/data-types-in-java) - In this article, we are going to learn about different data types like pre-defined, derived, and user-defined data types in Java with examples. - [Input and Output in Java](https://javahandson.com/input-and-output-in-java) - Learn input and output in Java with examples. Read keyboard input using a stream and the Scanner class, plus a BufferedReader vs Scanner guide. - [Java 25 Features: Overview of New Features](https://javahandson.com/java-25-features-overview-of-new-features) - Explore a high-level overview of Java 25 features, including language enhancements, JVM improvements, and performance updates. Understand what’s new in Java 25. - [List Interface in Java: ArrayList vs LinkedList vs Vector](https://javahandson.com/list-interface-in-java) - A deep dive into the List interface in Java, comparing ArrayList, LinkedList, and Vector — internals, performance, and when to use each. - [How Token Optimization works for AI Tools](https://javahandson.com/how-token-optimization-works-for-ai-tools) - Learn how token optimization works for GPT, Claude, and Gemini. Practical tips to cut API costs, speed up responses, and manage context windows. - [Spring Annotations Interview Questions – Events and Advanced Configuration](https://javahandson.com/spring-annotations-interview-questions-events-and-advanced-configuration) - Spring annotations interview questions answered in depth. Master @Value, @EventListener, @Async, @Conditional, CGLIB proxying with code. Beginner to advanced. - [Spring Bean Lifecycle Interview Questions – Scopes and 3-Level Caching](https://javahandson.com/spring-bean-lifecycle-interview-questions-scopes-and-3-level-caching) - Master spring bean lifecycle: scopes, BeanPostProcessors, circular dependency, and 3-level caching. Deep Q&A with code examples for interviews. - [Spring Core Interview Questions and Answers](https://javahandson.com/spring-core-interview-questions-and-answers) - Spring core interview questions with simple answers and code: IoC, DI, beans, scopes, @Autowired, bean lifecycle, circular dependency, @Profile, and more. - [JEP 514: Ahead-of-Time Command-Line Ergonomics Explained](https://javahandson.com/jep-514-ahead-of-time-command-line-ergonomics-explained) - JEP 514 simplifies Java AOT cache creation by replacing the two-step workflow with a single command, improving startup performance and usability. - [Java 25 vs Java 26: What's New, Key Differences, and Which One to Use](https://javahandson.com/java-25-vs-java-26) - Java 25 vs Java 26 compared - LTS vs feature release, finalized features, HTTP/3, previews, and which JDK version to choose in 2026. - [Agentic AI for Java developers](https://javahandson.com/agentic-ai-for-java-developers) - Agentic AI for Java developers explained — learn what AI agents are, how they work, and how to build a clear mental model using Java analogies and code. - [JEP 510 Safe Key Derivation in Java 25](https://javahandson.com/jep-510-safe-key-derivation-in-java-25) - JEP 510 Safe Key Derivation in Java 25 explains HKDF, salt, context, and how Java 25 safely derives multiple keys from one secret. - [JUnit 5 Tests with Claude Code: A Guide with Mockito Examples](https://javahandson.com/claude-junit-mockito) - Generate JUnit 5 tests with Claude Code: step-by-step prompts, Mockito mocks, edge cases, and best practices for clean, reliable Java unit tests. - [Sub-Agents in AI Systems: How Multi-Agent Orchestration Works](https://javahandson.com/claude-sub-agents) - Learn what sub-agents in AI systems are, how multi-agent orchestration works, and how to build agent pipelines. Beginner-friendly with Java code examples. - [Scoped Values in Java 25](https://javahandson.com/scoped-values-in-java-25) - Learn how Scoped Values in Java 25 enhance performance, fix ThreadLocal issues, and simplify context passing in virtual-thread applications. - [JEP 515 Ahead-of-Time Method Profiling Explained](https://javahandson.com/jep-515-ahead-of-time-method-profiling-explained) - JEP 515 Ahead-of-Time Method Profiling explains how Java reduces JVM warmup time by reusing method execution profiles to enable earlier JIT optimization. - [Structured Concurrency in Java 25 (JEP 505)](https://javahandson.com/structured-concurrency-in-java-25-jep-505) - Structured Concurrency in Java 25 (JEP 505) explained with examples, Joiners, best practices, and real-world use cases. how Java 25 simplifies concurrency. - [Claude Code for Java Developers: What It Is and How It Works](https://javahandson.com/claude-code-for-java-developers-what-it-is-and-how-it-works) - Claude Code for Java developers is an agentic CLI tool by Anthropic that reads your project, runs builds, and writes code — no copy-paste required. - [Installing Claude Code Java: Complete Setup and Configuration Guide](https://javahandson.com/java-claude-code-installation) - Installing Claude Code Java setup made easy — follow this step-by-step guide covering Node.js, authentication, Maven, Gradle, and first-run verification. - [CLAUDE.md Java Project Mastery: Teaching Claude Code Your Codebase](https://javahandson.com/java-claude-md) - Master CLAUDE.md Java project setup — teach Claude Code your Spring Boot conventions, build commands, and standards for consistent AI output every session. - [Writing Java Code with Claude Code: A Refactoring Tutorial](https://javahandson.com/claude-writing-java-code) - Guide to writing Java code with Claude Code: prompts, refactoring workflows, real examples, and best practices for Java developers. - [Java 25 vs Java 21 - Key Differences](https://javahandson.com/java-25-vs-java-21-key-differences) - Java 25 vs Java 21 - Key Differences explained with LTS changes in language features, APIs, performance, and whether you should upgrade. - [Custom Slash Commands in Claude Code for Java Workflows](https://javahandson.com/claude-custom-commands-java) - Learn how to create custom slash commands in Claude Code for Java workflows like source code, test generation, code review, security reviews, and documentation. - [Skills in Claude: What They Are and How SKILL.md Works](https://javahandson.com/claude-skills) - Skills in Claude let you give Claude custom instructions via a SKILL.md file. Learn what they are, how they work, and how to write your own. - [Model Context Protocol MCP: Connecting Claude to Your World](https://javahandson.com/claude-mcp) - Model Context Protocol MCP explained for Java developers. Learn how MCP works, how to connect Claude to your tools, and how to build MCP servers. With examples. - [AI Agents vs Chatbots](https://javahandson.com/ai-agents-vs-chatbots) - AI agents vs chatbots: learn how agents think, plan, and act autonomously — and what this shift means for Java developers building AI-powered apps. - [Enabling preview features in Java 25](https://javahandson.com/enabling-preview-features-in-java-25) - Enabling Preview Features in Java 25 is easy with javac, JVM flags, Maven, and Gradle. Learn how to use preview JEPs safely and explore new Java features. - [Introduction to Java 25](https://javahandson.com/introduction-to-java-25) - Introduction to Java 25 LTS - learn what Java 25 is, why it’s an important LTS release, and get a high-level overview of its new features. - [JEP 520: JFR Method Timing and Tracing Explained](https://javahandson.com/jep-520-jfr-method-timing-and-tracing-explained) - JEP 520: JFR Method Timing and Tracing adds exact method execution measurement to JFR, helping developers move from sampling-based guesses to performance proof. - [ForkJoinPool in Java](https://javahandson.com/forkjoinpool-in-java) - In this article, we will learn what is ForkJoinPool in Java. We will also know when to use ForkJoinPool, its features, and different methods. - [ExecutorService in Java](https://javahandson.com/executorservice-in-java) - In this article, we will learn about ExecutorService in Java. We will also learn when to use the executor services, its features, and different methods. - [Parallel stream in Java 8](https://javahandson.com/parallel-stream-in-java-8) - In this article, we will understand what is a parallel stream in Java 8. We will also learn when and how to use the parallel stream effectively. - [Grouping in Java 8](https://javahandson.com/grouping-in-java-8) - In this article, we will understand what is Grouping in Java 8. We will also learn about different variants of grouping methods with examples. - [Introduction to the Collectors class](https://javahandson.com/introduction-to-the-collectors-class) - This article is about the introduction to the collectors class and how it is better than the reduce method. We will also learn about the principles of Collectors API. - [Jagged array in Java](https://javahandson.com/jagged-array-in-java) - In this article, we will learn what is a jagged array in Java. Here we will also learn about 2D and 3D jagged arrays in Java with proper examples - [Three-dimensional array in Java](https://javahandson.com/three-dimensional-array-in-java) - In this article, we will learn what is a three-dimensional array in Java or 3D array in Java with proper examples. - [Arrays in Java](https://javahandson.com/arrays-in-java) - In this article, we will learn what is an array and the types of arrays in Java with proper examples. If you want to learn more about other Java, Java 8, or Spring concepts then please check the above menu options. Why Arrays?Types of ArraysSingle-dimensional arrayMulti-dimensional arraylength property An array is a collection of ## Courses Categories - [Java](https://javahandson.com/course-categories/java/) - [Java 8](https://javahandson.com/course-categories/java-8/) - [java language basics](https://javahandson.com/course-categories/java-language-basics/) - Java is a platform-independent, object-oriented programming language designed for simplicity, reliability, and performance. Understanding Java fundamentals is essential before moving on to advanced topics such as collections, streams, and frameworks. This section introduces core language concepts including data types, variables, constants, and the structure of a Java program. It also explains object-oriented principles, common output methods like System.out.print and System.out.println, and how data members work within a class. Additionally, it covers setting up the Java development environment by installing JDK 11 on Windows. Together, these articles provide a strong foundation for writing, understanding, and reasoning about Java programs. - [flow control statements](https://javahandson.com/course-categories/flow-control-statements/) - Hello guys this is flow control statements - [Understanding OOPS](https://javahandson.com/course-categories/java-oops/) - [java strings](https://javahandson.com/course-categories/java-strings/) - [java exceptions](https://javahandson.com/course-categories/java-exceptions/) - [java arrays](https://javahandson.com/course-categories/java-arrays/) - [java collections](https://javahandson.com/course-categories/java-collections/) - [Input and Output](https://javahandson.com/course-categories/java-io/) - [passing code with behavior parameterization](https://javahandson.com/course-categories/passing-code-with-behavior-parameterization/) - Behavior parameterization is a programming technique that allows a method’s behavior to be defined at runtime rather than being hard-coded. Instead of writing multiple versions of the same logic, we pass the behavior itself as a parameter, making the code more flexible, reusable, and easier to evolve. In Java, this idea existed even before Java 8 through interfaces and anonymous classes, but it became significantly more powerful and readable with the introduction of lambda expressions and functional interfaces. By parameterizing behavior, we can separate what a method does from how it does it, leading to cleaner APIs and better abstraction. This article focuses on understanding the concept of passing code as behavior, why it matters, and how it laid the foundation for modern Java features such as lambdas, streams, and functional-style programming. - [lambda expressions and functional interfaces](https://javahandson.com/course-categories/lambda-expressions/) - Lambda expressions and functional interfaces are the building blocks of functional programming in Java 8. They enable us to write cleaner, more readable code by treating behavior as a first-class concept. Java’s predefined functional interfaces and method references further simplify common programming patterns and reduce boilerplate. The articles below cover these concepts in a progressive manner—from basic lambda expressions to predefined functional interfaces with multiple arguments, and finally method references—helping you apply them confidently in modern Java applications. - [working with streams](https://javahandson.com/course-categories/working-with-streams/) - Streams provide a declarative way to process collections of data in Java. Instead of writing loops and managing mutable state, streams allow us to describe what we want to do with data—such as filtering, transforming, or aggregating—while the Stream API takes care of iteration and execution. Core stream operations like filtering, mapping, flatMap, and reduce form the backbone of most real-world stream pipelines. Filtering helps narrow down data based on conditions, mapping transforms elements into new forms, flatMap handles one-to-many transformations and nested structures, and reduce enables aggregation into a single result. The articles under this section explain these operations step by step, with practical examples, helping you understand how to build readable, efficient, and maintainable stream pipelines in everyday Java applications. - [collecting data with streams](https://javahandson.com/course-categories/collecting-data-with-streams/) - Collecting is the terminal phase of a stream pipeline where processed elements are accumulated into a final result. While intermediate operations like filtering and mapping transform the data, collectors define how that transformed data is gathered—whether into collections, maps, summary statistics, or grouped structures. The Collectors utility class provides a rich set of predefined collectors for common aggregation tasks such as summing values, generating summary statistics, grouping elements by a key, and partitioning data based on a condition. These operations allow complex data transformations to be expressed in a clear and declarative manner without manual iteration or mutable state. The articles in this section explore the Collectors API in detail, covering basic collectors as well as advanced grouping and partitioning techniques, helping you confidently collect and shape stream results in real-world Java applications. - [parallel data processing and performance](https://javahandson.com/course-categories/parallel-data-processing-and-performance/) - Java provides built-in support for parallel data processing to help applications make better use of multi-core processors. Parallel streams allow stream operations to be executed concurrently, automatically dividing work across multiple threads while preserving the declarative style of the Stream API. Under the hood, parallel streams rely on the ForkJoinPool, a framework designed for fine-grained parallelism and efficient work-stealing. Understanding how the ForkJoinPool works, how tasks are split and scheduled, and when parallel execution actually improves performance is critical to using parallel streams effectively. The articles in this section explain parallel streams and the ForkJoinPool from both a conceptual and practical perspective, helping you decide when parallel processing is beneficial—and when a sequential approach is the better choice. - [Operators in Java](https://javahandson.com/course-categories/operators-in-java/) - Operators in Java define how values and variables are manipulated within expressions. This section starts with a complete overview of Java operators, explaining their purpose and basic usage. It then dives into unary operators, which work on a single operand, and bitwise operators, which operate at the binary level and are commonly used in low-level and performance-sensitive code. Finally, the ternary operator is covered as a concise alternative to simple if-else statements, helping write cleaner and more readable conditional logic. Together, these articles build a strong understanding of how operators are used in everyday Java programs. - [multithreading](https://javahandson.com/course-categories/multithreading/) - [Java 25](https://javahandson.com/course-categories/java-25/) - [Java 25 Features](https://javahandson.com/course-categories/java-25-features/) - Java 25 (released September 16, 2025) is a Long-Term Support (LTS) version of the JDK, bringing 18 new JEPs and enhancements. It focuses on developer productivity (e.g., compact source files/instance main methods) and cleaner syntax. It also boosts performance via features like compact object headers, ahead-of-time method profiling, and improvements to the garbage collector. Java 25 further advances modularity (module import declarations) and scoped values, making concurrent and modular coding more expressive. As an LTS release, it is intended for broad adoption over the coming years, offering stability along with these innovations. - [Interview](https://javahandson.com/course-categories/interview/) - [Spring Interview](https://javahandson.com/course-categories/spring-interview/) - [Core Java Interview](https://javahandson.com/course-categories/core-java-interview/) - [ai-tools](https://javahandson.com/course-categories/ai-tools/) - [claude](https://javahandson.com/course-categories/claude/) - Claude is an AI assistant built by Anthropic, designed to be helpful, harmless, and honest. It can understand and generate human-like text, making it a powerful tool for tasks like writing code, explaining concepts, reviewing logic, and answering complex questions. For Java developers, Claude can assist with everything from debugging Spring Boot applications to generating boilerplate code and understanding framework documentation. Unlike a search engine, Claude holds a conversation — you can ask follow-up questions, refine your requirements, and get contextual responses tailored to your problem. - [Understanding Agentic AI](https://javahandson.com/course-categories/agentic-ai/) - [Java 26](https://javahandson.com/course-categories/java-26/) - [System Design](https://javahandson.com/course-categories/system-design/) - [Scaling & Data Basics](https://javahandson.com/course-categories/scaling/) - [Consistency & Partitioning](https://javahandson.com/course-categories/consisteny/) - [Dsa](https://javahandson.com/course-categories/dsa/) - [Arrays & Strings (Basics)](https://javahandson.com/course-categories/arrays/) - [Arrays & Strings (Two Pointers)](https://javahandson.com/course-categories/two-pointers/) - [Hashing](https://javahandson.com/course-categories/hashing/) - [Sliding Window](https://javahandson.com/course-categories/sliding-window/) - [Database Interview](https://javahandson.com/course-categories/database-interview/) - [System Design Interview](https://javahandson.com/course-categories/system-design-interview/) - [Latest-Updates](https://javahandson.com/course-categories/latest-updates/) - [tech-updates](https://javahandson.com/course-categories/tech-updates/) - [Messaging & Event-Driven](https://javahandson.com/course-categories/messaging/)