JavaScript, a versatile and widely-used programming language, has evolved significantly over the years. While initially associated with imperative and object-oriented programming paradigms, JavaScript has embraced functional programming as a powerful approach to building robust and maintainable applications. Functional programming emphasizes immutability, pure functions, and higher-order functions, enabling developers to write