functional-programming

Blocks, Procs, and Lambdas for functional programming

Ruby's closures—blocks, procs, lambdas—enable functional programming patterns. Blocks are anonymous code chunks passed to methods. Procs are objects wrapping blocks, callable with call. Lambdas are stricter procs—check argument count and return differ

Dry-rb gems for functional programming patterns

Dry-rb provides functional programming tools for Ruby. dry-validation creates complex validation schemas with type checking. dry-types defines strict types—coercion, constraints, sum types. I use dry-struct for immutable data structures with typed att

Enumerables and collection manipulation

Ruby's Enumerable module provides rich collection methods. map transforms elements; select/reject filter. reduce aggregates values. find returns first match; find_all returns all matches. group_by partitions by criteria. partition splits into two arra

Java Streams API for data processing

Java Streams provide a functional approach to processing collections with operations like filter, map, and reduce. I use stream() to create streams from collections and apply intermediate operations that are lazy and return new streams. Terminal opera