Functional Programming vs. Object Oriented Programming

Grudge Match: FP vs. OOP

Matthew Tyson
The Startup

--

Round 1. FIGHT!

Alright, that is it!

We are settling which paradigm is better once and for ALL.

Paradigm?

What is functional programming (FP)? What is object oriented programming (OOP)? Usually, you’ll get: “they are programming paradigms.”

And a satisfied smile.

As if that helps at all.

Great, now that I know they are paradigms, everything makes sense.

A paradigm is, according to Webster, “ a philosophical or theoretical framework of any kind.” Huh.

Tell you what, that is a useless and actually incorrect way of thinking about this thing.

WRONG.

Here’s the biggest incorrection: it makes its sound either-or.

Either you use FP, or you use OOP.

Actually, you will not find a significant software system that doesn’t use both approaches.

Why?

Because they are good for different things.

What FP and OOP are is different ways to contain functionality and package it for use — that is, how to create code-level components. What they are not is…

--

--