Learn more about computerscience with this collection
Understanding machine learning models
Improving data analysis and decision-making
How Google uses logic in machine learning
Functional programming (often abbreviated FP) is the process of building software by composing pure functions, avoiding shared state, mutable data, and side effects. Functional programming is declarative rather than imperative, and application state flows through pure functions. Contrast with object oriented programming, where application state is usually shared and colocated with methods in objects.
Functional programming is a programming paradigm, meaning that it is a way of thinking about software construction based on some fundamental, defining principles
6
10 reads
A pure function is a function which:
Pure functions have lots of properties that are important in functional programming.
Function composition is the process of combining two or more functions in order to produce a new function or perform some computation.
6
9 reads
Shared state is any variable, object, or memory space that exists in a shared scope, or as the property of an object being passed between scopes.
A shared scope can include global scope or closure scopes. Often, in object oriented programming, objects are shared between scopes by adding properties to other objects.
6
5 reads
An immutable object is an object that can’t be modified after it’s created. Conversely, a mutable object is any object which can be modified after it’s created.
Immutability is a central concept of functional programming because, without it, the data flow in your program is lossy.
6
7 reads
A side effect is any application state change that is observable outside the called function other than its return value. Side effects include:
7
6 reads
A higher order function is any function that takes a function as an argument, returns a function, or both. Higher order functions are often used to:
6
6 reads
Functional programming is a declarative paradigm, meaning that the program logic is expressed without explicitly describing the flow control.
6
6 reads
IDEAS CURATED BY
Other curated ideas on this topic:
Read & Learn
20x Faster
without
deepstash
with
deepstash
with
deepstash
Personalized microlearning
—
100+ Learning Journeys
—
Access to 200,000+ ideas
—
Access to the mobile app
—
Unlimited idea saving
—
—
Unlimited history
—
—
Unlimited listening to ideas
—
—
Downloading & offline access
—
—
Supercharge your mind with one idea per day
Enter your email and spend 1 minute every day to learn something new.
I agree to receive email updates