This repository is a collection of Java functional programming examples and practice code.
It is not a full project, but rather a set of small programs exploring different functional concepts in Java.
- Imperative vs Functional Style
- Functional Interfaces
- Consumer
- Function
- Predicate
- Supplier
- Lambdas
- Optionals
- Streams API
- Callbacks (JavaScript-style)
- Combinator Pattern (building validators)
The repository is organized into packages: src/main/java/ βββ FinalSection/ # Lambdas & callbacks βββ FunctionalProgramming/ # Core functional interfaces βββ Imperative/ # Imperative style examples βββ Optionals/ # Optional usage βββ combinatorpattern/ # Validator with combinator pattern βββ org/Awadhesh/ # Practice main file βββ streams/ # Streams API
-
Clone the repository:
git clone https://github.com/<Awadhesh-Gupta>/JavaFunctionalProgramming.git
-
Open in IntelliJ IDEA (or any IDE).
-
Run individual classes (Main.java) to explore examples.
π Note
This repo is meant only for practice and learning. It is not a production-ready project.