Skip to content

Latest commit

 

History

History
18 lines (12 loc) · 609 Bytes

File metadata and controls

18 lines (12 loc) · 609 Bytes

This repo contains examples and tools related to functional programming in Python.

Files

lambda_functions.py

This file demonstrates the use of lambda functions in Python. It includes examples for:

  • Adding two numbers
  • Checking if a number is even
  • Squaring a number

functional_tools.py

This file includes several functional programming tools:

  • square_numbers(): Applies the square function to each element in a list using map().
  • filter_even(): Filters out even numbers from a list using filter().
  • sum_numbers(): Computes the sum of numbers in a list using reduce().