Collections
Generics
Enums
Stream APIs
Unit Testing with JUnit
Debugging in Java
Practice
Assignment
Back end Track
Week 3 Overview
Previously in Week 2 - Advanced OOP you learned to:
- Organise and reuse code through class hierarchies using Inheritance.
- Decouple your implementation from your contracts using Interfaces.
- Write flexible code that works with many different implementations using Polymorphism.
- Increase reliability of your application with Error Handling in Java.
This week, you will learn how to store, process, and validate data efficiently in Java. You will move from fixed-size arrays to Java's collections, use generics and enums to make your code safer, process collections with streams, and practice testing and debugging in IntelliJ IDEA.
Learning goals
By the end of this week, you will be able to:
- Java Collections: Use
ArrayList, HashSet, and HashMap as flexible, resizable data structures that replace the fixed-size arrays you have used so far.
- Generics: Write classes and methods that work with different types while keeping full type safety, without manual casting.
- Enums: Represent fixed values, such as statuses or options, instead of relying on magic strings or numbers.
- Stream API: Filter, map, transform, and collect data in a modern, readable way.
- Unit Testing with
JUnit 5: Apply the testing ideas from the Core program to Java by writing unit tests with the Arrange-Act-Assert pattern.
- Debugging in IntelliJ IDEA: Set breakpoints, step through code, and inspect variables at runtime to find and understand problems.
The HackYourFuture curriculum is licensed under CC BY-NC-SA 4.0
*https://hackyourfuture.net/*

Built with ❤️ by the HackYourFuture community · Thank you, contributors
Found a mistake or have a suggestion? Let us know in the feedback form.