Best of Functional Programming2025

  1. 1
    Article
    Avatar of itnextITNEXT·1y

    Programming and architectural paradigms

    Different programming paradigms, such as object-oriented, functional, and procedural programming, each have their unique strengths and are suited to particular tasks. These paradigms are also reflected in various distributed system architectures like SOA, microservices, and data mesh. The choice of paradigm and technology depends on specific project requirements and the context in which they're applied.

  2. 2
    Article
    Avatar of communityCommunity Picks·1y

    OOP: the worst thing that happened to programming

    The post argues that object-oriented programming (OOP) is detrimental to programming and discusses its drawbacks compared to functional programming (FP). It highlights issues with OOP constructs such as classes, methods, inheritance, and encapsulation, and claims that these contribute to overcomplicated code and poor programming practices. The author recommends avoiding OOP in favor of FP, which is seen as simpler and more efficient. The post suggests adopting languages and techniques that favor functional paradigms.

  3. 3
    Article
    Avatar of medium_jsMedium·1y

    OOP vs. Functional is Dead

    Modern programming language classifications based on paradigms like functional or object-oriented are becoming less useful as languages increasingly blend multiple paradigms. Instead, classifying languages by their memory management approach offers a more practical framework. Languages can be categorized as Sovereign (manual memory management), Guardian (ownership/RAII), Custodian (garbage collection), or Accountant (automatic reference counting). This classification impacts performance, safety, and developer experience, providing clearer insights when selecting a language for a specific application domain.

  4. 4
    Article
    Avatar of infoworldInfoWorld·1y

    8 ways to do more with modern JavaScript

    The post outlines eight essential concepts to enhance JavaScript programming, including the use of 'const' for variables, understanding collections with functional operators, using promises and async/await for asynchronous tasks, and the importance of scopes and closures. It emphasizes syntax shortcuts like spread and destructuring, strategies for effective error handling, the flexibility of programming paradigms JavaScript offers, and the valuable role of AI assistance in coding.

  5. 5
    Video
    Avatar of primeagenThePrimeTime·43w

    I'm switching languages again...

    A developer shares their experience learning Elixir, highlighting two key features that attracted them to the language: pattern matching in function definitions and the 'with' construct for error handling. They demonstrate how Elixir's pattern matching allows for declarative programming by defining multiple function clauses that match different input patterns, eliminating the need for complex if-else chains. The 'with' construct is praised for its ability to chain operations cleanly while handling errors gracefully, similar to promise chains but with pattern matching capabilities. The developer compares Elixir favorably to Rust and Go, noting that while Rust has pattern matching, it lacks function overloading, and that Rust becomes inconvenient at higher complexity levels.

  6. 6
    Article
    Avatar of stitcherstitcher.io·46w

    The pipe operator in PHP 8.5

    PHP 8.5 introduces the pipe operator (|>) that allows chaining function calls in a more readable way. Instead of deeply nested function calls or temporary variables, developers can pipe values through a series of transformations. The operator works with first-class callables for single-argument functions or closures for multi-argument functions. While currently requiring closures for complex operations, future partial function application support could make it even more concise.

  7. 7
    Article
    Avatar of baeldungBaeldung·1y

    How to Convert Nested Loops to Stream in Java

    Java Streams, introduced in Java 8, offer a declarative and efficient way to handle data by replacing complex nested loops. This post explores transforming nested loops into Streams, covering basic operations, filtering, and short-circuiting iterations. It highlights how streams can simplify complex transformations, improve readability, and enable parallel execution. However, for simple or performance-critical tasks, traditional loops may be more suitable.

  8. 8
    Article
    Avatar of lnLaravel News·46w

    The Pipe Operator is Coming to PHP 8.5

    PHP 8.5 introduces the pipe operator (|>) scheduled for release on November 20, 2025. This operator enables chaining multiple callable functions from left to right, passing values through them sequentially. It improves code readability by eliminating nested function calls and temporary variables, allowing developers to write more linear and comprehensible data transformation pipelines using first-class callables.

  9. 9
    Article
    Avatar of rubylaRUBYLAND·51w

    Railway Pattern

    The Railway Pattern enables fault-tolerant function composition by chaining operations that can either succeed or fail gracefully. Using Ruby gems like Dry Monads and Pipeable, developers can build robust pipelines where each step produces either a Success or Failure result, allowing errors to bubble up without breaking the entire flow. The pattern is demonstrated through building an API client that handles HTTP requests, JSON parsing, validation, and data modeling as a single composable pipeline, making code more resilient to network issues and data problems.

  10. 10
    Article
    Avatar of communityCommunity Picks·49w

    reactjs/react-basic: A description of the conceptual model of React without implementation burden.

    A theoretical exploration of React's conceptual model that breaks down UI development into fundamental concepts like transformation, abstraction, composition, state management, memoization, and algebraic effects. The document presents React as a system for transforming data into UI representations through pure functions, emphasizing how complex interfaces can be built through composition of simpler abstractions. It covers advanced concepts like memoization for performance optimization, state management patterns, and introduces algebraic effects as a way to handle cross-cutting concerns like theming without prop drilling.

  11. 11
    Article
    Avatar of tigerabrodiTiger's Place·1y

    Branded Types in TypeScript

    Branded types in TypeScript are a way to simulate nominal typing by adding a unique brand to a base type, making structurally identical types incompatible at compile time. This is useful for preventing bugs caused by passing the wrong type of value. The concept originated in the functional programming world and has been adopted by the TypeScript community to ensure type safety.

  12. 12
    Article
    Avatar of javarevisitedJavarevisited·1y

    Top 15 Java Stream and Functional Programming Interview Questions and Answers

    Java 8 introduced significant changes, including the Stream API and functional programming idioms, making it essential for Java developers to understand these concepts for interviews. The post provides a list of common Java Stream and functional programming interview questions with answers, covering essential topics like map(), filter(), and flatMap() methods, alongside various functional interfaces. With investment banks and other companies heavily relying on these skills, mastering Java 8 is crucial for modern Java development.

  13. 13
    Article
    Avatar of graphitedevGraphite.dev·52w

    How we organize our monorepo to ship fast

    Graphite's approach to software architecture prioritizes developer velocity by utilizing a monorepo structure with TypeScript throughout, composable modules instead of microservices, and functional programming principles. Their infrastructure includes tools like Turbo for efficient builds and a single server image for simplified deployment, enabling them to ship over 1,000 pull requests monthly. The team's strategic decisions focus on balancing simplicity and performance, opting for shared code and modular design over conventional microservices complexity.

  14. 14
    Article
    Avatar of jsdeveloperJavaScript Developer·1y

    Understanding JavaScript Currying with a Real-World Application

    This post explains JavaScript currying, breaking down the complex concept into simple language and practical examples to show its purpose and benefits in programming.

  15. 15
    Article
    Avatar of hnHacker News·1y

    pyper-dev/pyper: Concurrent Python made simple

    Pyper is a flexible framework for concurrent and parallel data-processing using functional programming patterns. It simplifies writing ETL systems, data microservices, and data collection with its intuitive API and clean abstractions. Pyper supports threaded, multiprocessed, and asynchronous tasks, ensuring safety and efficiency with lazy execution and zero sub-dependencies. It provides a unified API for threading, multiprocessing, and asyncio, enabling the creation of composable pipelines.

  16. 16
    Article
    Avatar of freekFREEK.DEV·21w

    Partial Function Application is coming in PHP 8.6

    PHP 8.6 will introduce Partial Function Application, a feature that allows developers to create pre-configured callables by providing some arguments upfront while using placeholders for others. This functional programming technique enables more flexible function composition and reusability.

  17. 17
    Article
    Avatar of Marmelabmarmelab·25w

    TypeScript Types as a Programming Language

    TypeScript's type system is Turing complete and can be approached as a programming language. Generic types function like type-level functions, conditional types enable branching logic with the extends keyword, the infer keyword acts as variable assignment for extracting types, recursion allows iteration over arrays and complex structures, template literals enable string manipulation at the type level, and mapped types provide iteration over object properties. These capabilities enable creating sophisticated type utilities like CRUD generators, middleware type inference, and dynamic method generation that reduce code duplication while improving type safety and IDE autocomplete.

  18. 18
    Video
    Avatar of awesome-codingAwesome·45w

    PHP is getting a huge quality-of-life upgrade | Syntax Error

    PHP 8.5 introduces the pipe operator, a functional programming feature that allows chaining data transformations in a readable top-to-bottom flow. The operator passes values from left to right as function arguments, eliminating nested function calls and improving code readability. Future partial function application support will further enhance the pipe operator's flexibility by allowing placeholder syntax for multi-argument functions.

  19. 19
    Article
    Avatar of python_dev963Python Developers·1y

    Pyper: Concurrent Python Made Simple

    Pyper is a new and flexible framework for concurrency and parallelism in Python, emphasizing the functional programming paradigm. It offers an intuitive API, prioritizes safety, and is designed for efficiency, all while being a lightweight and pure Python package with no dependencies.

  20. 20
    Article
    Avatar of medium_jsMedium·49w

    The Art of Doing Everything All at Once in Python! Hence, Multithreading.

    Python's map(), filter(), and reduce() functions provide functional programming alternatives to traditional loops for data transformation and filtering. Multithreading enables concurrent execution of tasks, particularly useful for I/O-bound operations, though Python's Global Interpreter Lock (GIL) limits true parallelism for CPU-intensive tasks. Thread synchronization using locks prevents race conditions when multiple threads access shared resources. These concepts become essential for building scalable, performant applications beyond simple scripts.

  21. 21
    Video
    Avatar of codeheimcodeHeim·1y

    #85 Golang - Functional Programming: First-Class Functions, Closures & More!

    This post provides an in-depth look at functional programming in Golang, focusing on first-class functions, higher-order functions, and closures. Examples are provided to demonstrate how functions can be treated as variables, passed as arguments, and returned from other functions. The concept of closures, where functions retain access to their environment, is also discussed through practical examples.

  22. 22
    Article
    Avatar of habrhabr·32w

    Predicate Pattern in Go

    Explores implementing the predicate pattern in Go to create elegant, filterable search methods. Demonstrates building a process finder that accepts predicate functions (functions returning bool) through builder methods like ByTitle() and ByPID(). Shows how to enhance developer experience by converting filter functions into methods on an empty struct, enabling IDE autocomplete for filter options while maintaining clean, idiomatic code.

  23. 23
    Article
    Avatar of elixirstatusElixirStatus·24w

    State of Elixir 2025

    Over 1,000 Elixir developers participated in the 2025 State of Elixir survey, revealing a senior-heavy community (median 13+ years experience) that values concurrency, fault tolerance, and developer joy. Phoenix and LiveView dominate the ecosystem, with most teams running small deployments (1-5 nodes) in compact teams. While Elixir delivers strong business impact through reliability and faster delivery, hiring remains challenging. The community prioritizes LSP stability, type system completion, and native tooling over new features, with particular gaps in UI components and AI/ML integration.

  24. 24
    Article
    Avatar of freecodecampfreeCodeCamp·30w

    How to Use Closures in Go

    Closures in Go are functions that capture and retain access to variables from their surrounding scope, even after the outer function has finished executing. The guide covers how Go's escape analysis moves captured variables to the heap, common pitfalls like the loop variable trap where all closures reference the same variable, and practical patterns including memoization, event handlers, and concurrent pipelines. It explains how to create closures through various methods, handle them safely in goroutines using channels or mutexes, and addresses memory implications of heap-allocated captured variables.

  25. 25
    Article
    Avatar of hnHacker News·35w

    How to stop functional programming

    A satirical piece that demonstrates the absurdity of banning functional programming practices in the workplace. Through code examples, it shows how attempting to avoid pure functions and functional concepts leads to unnecessarily complex and awkward solutions, highlighting the inherent value of functional programming principles even when explicitly prohibited.