Skip to content
DevMeme
5966 of 7435
FP kingdom praises monoids while scorning OOP builders in castle standoff meme
FunctionalProgramming Post #6535, on Feb 17, 2025 in TG

FP kingdom praises monoids while scorning OOP builders in castle standoff meme

Why is this FunctionalProgramming meme funny?

Level 1: Castles in the Sandbox

Imagine two kids in a sandbox, each building their own little castle. One kid is using a super fancy method – let's say he has a special set of puzzle pieces and a strict rulebook for how to stack them. He’s very proud of how "perfect" his castle is because he followed all his special rules. The other kid is using a more common-sense method – just regular blocks and a simple, familiar plan. He’s really pleased with how sturdy and neat his castle looks. Now, instead of admiring each other’s castles, they start yelling across the sandbox. The first kid shouts, "Your way of building is dumb and clumsy! My way is the right way!" The second kid fires back, "No, your way is overcomplicated and weird! My way is the best!" Each thinks their own approach is superior and calls the other’s approach silly names. It’s a funny scene because, from the outside, both castles are actually pretty nice – they were just built differently. The adults watching can’t help but smile, because the kids are basically arguing over whose style is better, even though there’s more than one good way to build a castle. That’s exactly what this meme is like: two groups of programmers each convinced their way of writing code is the only good way, making fun of each other, even though both ways can work just fine. It’s a playful picture of a petty argument – like kids saying "my toy is better than your toy" – and it makes us laugh because we’ve all seen people argue like that over nothing important.

Level 2: Monads and Factories

Let’s break this down in simpler terms. The cartoon is showing two opposing sides: the left side represents Functional Programming (FP) and the right side represents Object-Oriented Programming (OOP). They’re using some pretty fancy words, but really it's a joke about how each side has its own favorite tools and how they sometimes mock each other. If you’re newer to these concepts, here’s what those terms on each side mean:

On the FP side (left castle) – Functional programming is a style of coding where you use functions as the main way to build logic, avoid changing state (no modifying variables willy-nilly), and often borrow ideas from math to make code more predictable. Some terms mentioned are:

  • Semigroup: This is an algebraic term, but in programming you can think of it simply as "things that can be combined". If you have an operation that lets you combine two values into one (for example, combining two strings by concatenation, or adding two numbers), and if that operation is associative (meaning it doesn’t matter how you group the operations – e.g. "A + (B + C)" gives the same result as "(A + B) + C"), then those values form a semigroup with respect to that operation. Example: Strings form a semigroup with the combine operation being "concatenate". So "Hello " + "World" (combining the two strings) can be done in any grouping and you'd still get "Hello World".
  • Monoid: A monoid is just a semigroup with one extra feature: an identity element. That’s a special value that you can combine with others without changing them. Using the string example, the identity element is the empty string "" (because "Hello" + "" is still "Hello"). For addition, the identity is 0 (since (5 + 0 = 5)). So a monoid is basically "things that can be combined (associatively) and there’s a do-nothing value". In functional programming, recognizing something as a monoid is handy because it means you can fold or reduce a bunch of those things reliably. Many data types (lists, numbers, etc.) are monoids under the right operation.
  • Functor: In programming, a functor is something you can map a function over. Think of a list: if you have a list of numbers and a function that doubles a number, you can apply (map) that function to the whole list to get a new list of doubled numbers. That means the list is acting like a functor – it let you take a function and apply it inside its structure. In many languages (like Haskell or Scala), Functor is a formal concept (often as an interface or type class) for "things that support a map operation". Other examples: an Option or Maybe type (which holds either a value or nothing) can be a functor because you can map a function over the contained value if it exists. Functor, weird as the word sounds, basically captures the idea of "I have a box/container, and I can apply a transformation to the contents inside the box".
  • Monad: Okay, monads are infamous for sounding complicated, but let's demystify. A monad is like a design pattern (though FP folks might cringe at it being called that) for chaining operations together. It’s a way to take a value with context and pass it through a series of functions, where each function might add its own context or effect. Another way people put it: a monad is something that lets you do steps one after another while keeping track of something (like potential failure, or a log, or an asynchronous wait). The classic beginner example is the Maybe (or Option) monad: imagine you have a bunch of computations where something might come out empty or null at any step. If you wrap your value in a Maybe/Option, you can chain operations on it without constantly writing if (value is present) ... checks; the monad takes care of propagating the "nothing there" case. In a sense, the monad "knows" how to handle the context (like "this might be missing") so you can focus on the main logic. Many languages have something like this: e.g., Java’s Optional, JavaScript’s Promises for async operations, or C#’s LINQ for chaining queries – all these can be seen as monad-like structures. The joke in the meme is that FP people treat monads as almost magical ("our noble Monad"), because monads are a big deal in Haskell and other FP languages for handling everything from I/O to errors in a structured, pure way. They do have a formal definition with laws (left identity, right identity, associativity), but practically, you can think of them as a pipeline for values with context, ensuring each step is handled properly.

So, the FP side is basically bragging about these abstract but powerful concepts (Semigroup, Monoid, Functor, Monad) that help make code declarative and encourage safe, testable designs. These ideas are common in languages like Haskell, F#, or Scala (when using Scala in a functional style).

On the OOP side (right castle) – Object-oriented programming is a style where you organize code as objects (like little "actors" that hold data and have functions, called methods, to do things). OOP is big on designing classes and relationships, and over the years, people noticed recurring good ways to structure these. Those became known as design patterns (documented solutions to common design problems). The ones listed in the meme are classic patterns from the OOP playbook:

  • Factory (Factory Method or Abstract Factory): This is a pattern for creating objects. Instead of making objects directly with new, you call a factory method or use a factory object whose job is to create instances for you. Why do that? It decouples the creation of objects from the rest of your code. For example, if you have a game and need different types of Enemy objects, you might have an EnemyFactory that decides whether to produce a Goblin, Troll, or Dragon based on some input. The calling code just says Enemy enemy = enemyFactory.createEnemy("troll"); and gets an Enemy back, without worrying about the exact subclass or constructor details. Factories are useful when the creation logic is complex or when you want to swap out the concrete class being created (maybe today it creates a local object, but tomorrow it might create a remote object – the code that uses it wouldn’t have to change). It’s a very common pattern in languages like Java and C++.

  • Builder: The Builder pattern helps construct a complex object step by step. Imagine you have a Computer object with lots of parts (CPU, GPU, RAM, etc.). Instead of a huge constructor with 10 parameters (which is hard to read and easy to mix up), you use a ComputerBuilder. This builder has methods like addCPU(String type), addRAM(int gb), etc. You call these in chain and finally call build() to get the assembled Computer object. It’s like having a building plan and assembling the product gradually. Builders are common in languages like Java when you have objects with many optional properties. They make the code more readable. For example:

    Computer pc = new ComputerBuilder()
                     .addCPU("Intel i9")
                     .addRAM(32)
                     .addStorage("1TB SSD")
                     .build();
    

    This reads almost like English and you don't have to remember the order of constructor parameters. The meme calls this pattern "backward" (as an insult from the FP side), implying that functional folks might consider it an unnecessary ceremony if you could just use simple functions or data composition to accomplish the same assembly.

  • Adapter: An Adapter is like a translator or a plug converter between code interfaces. Suppose you have a piece of code that expects to call method X on some object, but you have an object that offers similar functionality via method Y with a different signature. You write an Adapter class that implements the interface expected by the first piece of code and internally calls the other object's method. Basically, it "adapts" one interface to another. A classic real-world analogy: think of a power plug adapter that lets a device with a three-prong plug work in a two-prong outlet – it converts the interface of the plug into one the outlet accepts. In code, for example, if you have a new logging library that uses a method logMessage(String msg) but your existing code is full of calls to write(String msg) from an old logger interface, you could create an Adapter that has a write(msg) method (so your old code calls it), and inside it calls logMessage(msg) on the new library. The adapter pattern is very common for integrating libraries or legacy code with new code. The meme calls the Adapter "brutish", joking that from the FP side's lofty viewpoint, these OOP workarounds seem clunky.

  • Strategy: The Strategy pattern is about having multiple algorithms or behaviors and choosing one to use at runtime. You define a common interface for the behavior (e.g., a Sorter interface with a method sort(List<T> data)), and then have multiple implementations of that interface (QuickSortStrategy, MergeSortStrategy, etc., each with its own sort algorithm). When your program runs, you can swap out which strategy implementation to use (for example, pick QuickSort for smaller data sets and MergeSort for larger ones, or different game AI strategies for easy vs hard mode). It’s basically a plug-and-play approach for algorithms. In everyday terms, think of a navigation app that lets you choose driving vs walking vs biking directions – each option is a different strategy following the same basic rules of the road. In code, without first-class functions, Strategy is a handy pattern; with first-class functions (like in JavaScript or Python), you might just pass different function objects or callbacks instead of making separate classes. To a functional programmer, the Strategy pattern can look like an elaborate way to do something that could be achieved by simply passing a function. That’s why an FP devotee might tease that Strategy (and other patterns) involve a lot of boilerplate – hence the meme's label "Their wicked Strategy".

In the cartoon, the FP side calls their own tools things like "glorious" and "heroic" while calling the OOP tools "primitive" and "wicked". This is a humorous exaggeration of how die-hard fans of each side sometimes talk. Really, both sets of ideas – the FP abstractions and the OOP patterns – are useful in different situations. A new developer might start with OOP ideas (since languages like Java, C#, or Python commonly use classes, objects, and patterns) and learn these design patterns to structure larger programs. Later, you might encounter functional programming concepts (perhaps in a language like Haskell, or in portions of a multi-paradigm language like Scala, Kotlin, or even new features in JavaScript/TypeScript) and see that they offer a different, very elegant way to solve problems by focusing on immutable data and pure functions.

The meme is funny once you know these terms because it’s like seeing two rival teams cheer and jeer at each other. Team FP is using academic-sounding, math-like words – imagine them like wizards in robes, proclaiming "Monads will save us all!" – and Team OOP is using engineering terms – imagine them as builders in hard hats, saying "We constructed this system with our trusty patterns!" Each side is very proud of their own approach and a bit dismissive of the other. For instance, an FP fan might joke that an OOP codebase is over-engineered with needless classes, while an OOP fan might joke that FP code is so abstract you need a secret decoder ring (or a math degree) to understand it. This comic takes that rivalry and plays it out as a literal castle siege with labels that sound like grand titles or insults.

In plain terms: the left side of the image highlights functional programming concepts (using math-like rules and functions to build programs), and the right side highlights object-oriented design patterns (using established object designs and blueprints to build programs). The joke is that each side is over-the-top proud of its way and mocks the other side as if they were barbarians who "don't get it." If you're new to these ideas, don't be scared off by the big words – every programmer starts somewhere, and these are just different ways to solve problems. The meme exaggerates the rivalry for humor. It’s as if two kids built two different cool sandcastles and are each insisting "My way of building is the only right way!" In reality, good developers often learn a bit of both paradigms and pick the right tool for the job. The cartoon just makes us laugh by showing how silly it looks when each camp thinks the other is doing everything wrong. Once you understand the lingo (monoids or factories), you can appreciate the tongue-in-cheek DeveloperHumor here: it's poking fun at our tendency to form camps in programming and engage in this kind of lighthearted TechSatire about whose approach is superior.

Level 3: Tribal Tower Defense

From a seasoned developer’s perspective, the humor in this cartoon comes from how accurately it captures a classic programming holy war – and it even dresses it up in medieval cosplay. Two castles on opposing hills, divided by a river, immediately signal a standoff between rival camps (a familiar castle meme scenario in tech humor). Here those camps are two programming paradigms, each literally flying banners of its favorite ideas. We've got "towers of abstraction" facing off across the divide. On one side, the Functional Programming gurus extol the virtues of algebraic purity ("Look at our heroic Functor and noble Monad, so elegant and principled!"). On the opposite side, the Object-Oriented veterans tout their pragmatic design patterns ("Behold our mighty Factory and trusty Strategy, proven in battle!"). The meme cranks this up to eleven by labeling one side "Our Blessed FP" and the other "Their Barbarous OOP." It's funny because it's true enough – in tech circles, people do get almost religious about these things – but of course it's exaggerated to the point of absurdity. Seeing terms like Monad and Factory treated as opposing royal lineages is a delightful nod to how seriously developers can take these abstract concepts. If you've ever witnessed a heated debate between, say, a Haskell enthusiast and a Java architect, you know it can feel like watching two knights jousting: one wielding a lance of math and the other a shield of UML diagrams. The cartoon nails that vibe down to the petty name-calling. Calling someone’s cherished Builder pattern "backward" or dismissing a Monad as some inscrutable sorcery – those are the kinds of barbs that get thrown (in slightly more civil words) on internet forums and during architecture discussions. The humor lies in recognizing this familiar drama and seeing it play out with castle towers and medieval banners as if these programming constructs were feuding kingdoms.

Many veteran developers have lived through cycles of this FP vs OOP rivalry. Perhaps you remember the first time you ventured out of your comfort zone – say, a hardcore Java developer picking up a Haskell tutorial, or a Lisp wizard stepping into an enterprise Java codebase. Those moments can feel like landing in a foreign country with its own language and customs. This meme taps into that culture shock. A senior dev will recall times when codebases felt like foreign lands: maybe that sprawling Java project where every other class was a Factory or Singleton and you needed a UML map to navigate the design patterns. Or the flip side: joining a Scala project where business logic was written in terse functional style and suddenly you're swimming in terms like monoids, functors, and lambda lifts. The paradigm_tribalism portrayed in the cartoon – with each side convinced the other speaks nonsense – is something we’ve actually experienced. It's the memory of trying to debug a colleague's code and realizing you not only have a bug to fix but an entire paradigm to grok. The meme gets a knowing laugh because we've all been that baffled traveler at some point. Think of the junior dev who learned OOP design patterns in school opening a file in an FP-heavy codebase for the first time: "What on earth is Monoid<Product> or Functor<Order>? Where are my classes and objects?!" Or vice versa: a functional programming devotee reading an unfamiliar Java codebase: "Why do we have a DataObjectBuilderFactoryFactory? Are we building builders now?" Those are real reactions we've either had or witnessed, and they map perfectly onto the cartoon’s exaggeration of each side calling the other's practices barbaric or backwards.

By the time you've been in the industry a while, you realize these paradigm wars never truly have a winner – but that doesn’t stop people from passionately taking sides. This meme highlights the almost comical intransigence of both camps. Each side has its war stories and scars. The FP folks might recount the nightmare of inheriting a gigantic OOP codebase full of design patterns piled on top of each other (Factories within factories, Strategies that needed their own Strategies – spaghetti code in an object-oriented flavor, and yes, that kind of over-engineering does happen!). Meanwhile, the OOP folks have their own tales of woe, like grappling with an over-engineered Haskell library where half the battle was deciphering the jargon (when a function name is (>>=) and the documentation says "it's bind for a Monad", that can feel pretty arcane if you're not an initiate). The meme’s language – "glorious semigroup" vs "brutish adapter" – echoes how each side tends to view the other’s solutions: either gloriously elegant or needlessly barbaric. As a senior dev, you’ve likely swung on that pendulum of opinion yourself. Early in your career you might have thought the Adapter pattern was the height of cleverness ("I can make any interface work with any code! Amazing!"). Then later you discover map/filter/reduce in a functional style and suddenly adapters feel like clunky bureaucracy – why not just transform the data directly? Or you start off enamored with Haskell’s purity and monads, but then you work on a quick-and-dirty Python script and appreciate how straightforward imperative code can be. These experiences mellow you out. That’s why an experienced developer can laugh at this standoff: we see a bit of our younger, more opinionated selves in those castle defenders shouting "barbarian!" at the other camp.

The systemic issues behind this meme are also pretty relatable. Tech communities tend to form echo chambers – if you hang out in a purely FP group, you’ll hear only about the wonders of algebraic data types and how OOP is outdated. In an enterprise OOP environment, you might never hear about monads except as the butt of a joke about how confusing they are. This split gets reinforced by incentive structures: maybe your company invested in an OO framework years ago, so all training and hires focus on that skillset; switching to an FP approach would be risky and costly (and might step on some senior architects’ toes). Or perhaps a new CTO is a functional programming advocate and suddenly there’s a top-down push to rewrite crucial components in a pure FP style – leaving some team members feeling alienated because their hard-earned OOP expertise is being sidelined. These shifts can breed resentment and deepen the "us vs them" mentality. It’s much like our two meme kingdoms fortifying their defenses rather than trying to understand each other. The human factor is big: pride, familiarity, and fear of the unknown often keep smart people clinging to what they know. It's not that one side lacks intelligence; if anything, it's that both sides are so clever in their own domains that they can’t resist a bit of contempt for the other domain’s complexities. Bridging that gap takes humility and effort – easier to lob cannonballs of snark from your comfy castle.

In the end, this meme lands with senior devs because it’s poking fun at something we've all seen (and maybe contributed to) – the language wars and paradigm feuds that are part of developer culture. It's a playful reminder that, hey, we’ve been making castles out of our favorite abstractions and lobbing stones at the other camp for ages. Whether it was Java vs Python, OOP vs FP, or even older battles like structured programming vs goto, the scenery changes (and thank goodness the jargon evolves – imagine a castle labeled "GOTO" sneering at a castle labeled "Structured Loop"!). The castle standoff format perfectly captures the stubborn standoffishness that can happen. And because we recognize that stubbornness in ourselves, we can laugh at it. A veteran coder sees this comic and chuckles, perhaps thinking, "Been there, fought that." Then they might share it in the team chat with an equal-opportunity jab like, "Looks like our microservice team vs our data science team last week!" – because at the end of the day, we all know both sides have their merits, and the real folly is how seriously we sometimes take the fight. It's a gentle self-own for the entire dev community, wrapped in a nerdy Monty Python-style cartoon. And if nothing else, it reminds us that calling someone else's code "barbarous" probably says more about our own bias than their code – a very level-headed insight wrapped in humor.

Level 4: Category Theory Crusade

At the highest level, this meme caricatures a clash between two distinct theoretical foundations in programming. On the left hill, the FunctionalProgramming camp raises banners of abstract algebra and category theory – they're literally defending mathematical abstractions. Concepts like Semigroup, Monoid, Functor, and Monad are not just whimsical jargon; they come straight from formal math. For instance, a Monoid in abstract algebra is defined as a set (M) equipped with a binary operation (let's call it (\otimes)) that is associative and has an identity element (e). Formally:

(a \otimes b) \otimes c = a \otimes (b \otimes c) \\
a \otimes e = a = e \otimes a

These equations mean you can group operations arbitrarily (associativity) and there's a "do nothing" element (e) (the identity) that leaves any value unchanged. FP devs love such laws – they guarantee that combining things yields consistent results, no matter the order. Functors and Monads come from category theory: a Functor is essentially a mapping between categories (in programming terms, a type that you can map a function over, like applying a function to each element in a list or to the value inside an Option), and a Monad is an even more powerful abstraction that allows chaining operations while carrying along context (like state, or the possibility of failure). In category theory parlance, “a monad is just a monoid in the category of endofunctors” – a tongue-twister that FP enthusiasts chuckle at because it's technically true (it describes a monad in mathematical terms) and utterly cryptic to the uninitiated. The key point is that the FP castle’s towers are built on rigorous algebraic laws: each of those terms (Semigroup, Monoid, etc.) comes with precise definitions and properties proven in math. This gives the FP side a sense of mathematical nobility – hence the meme’s dramatic labels like "Our glorious Semigroup" and "Our noble Monad". To the functional programming faithful, these abstractions are elegant tools forged in the fires of lambda calculus and type theory, worthy of reverence.

On the opposite hill stands the ObjectOrientedProgramming camp, built on a very different kind of foundation: not pure math, but decades of DesignPatterns_Architecture and hands-on software engineering wisdom. Their towers – Factory, Builder, Adapter, Strategy – hail from the famous 1994 “Design Patterns” book by the Gang of Four (Gamma et al.), which catalogued classic solutions to common software design problems. Unlike category theory's universal laws, design patterns are more like battle-tested blueprints. Each pattern addresses a recurring challenge in code architecture. For example, a Factory method abstractly creates objects for you, deciding which specific subclass or type is needed behind the scenes – much like a toy factory where you place an order and get a toy without knowing the exact assembly steps. A Builder pattern provides a step-by-step way to construct a complex object: instead of one huge constructor call with 12 parameters (which is error-prone and hard to read), a Builder lets you set up parts of the object gradually and then assemble it, like a chef following a recipe to create a complex dish one step at a time. An Adapter acts as a translator between incompatible interfaces – imagine you have a square peg and a round-hole socket; an Adapter is the special piece that lets the square peg fit into the round hole by converting the interface. The Strategy pattern defines a family of algorithms, encapsulates each one, and makes them interchangeable – it's like having multiple approaches to solve a problem (say, different sorting methods) and you can swap them in and out easily by changing an object’s strategy. These OOP patterns form an informal theory of practical design. They were never about mathematical proof; instead, they emerged from community experience and were validated by successful use in many codebases. In the OOP kingdom, knowing your design patterns is a mark of pride (almost a chivalric code). A seasoned Java or C++ developer might speak of patterns with the same reverence an FP guru reserves for monads. So in the meme’s right-side castle, they have their own grandiose banners – but notably, they’re phrased from the left side’s mocking perspective as "Their primitive Factory" or "Their backward Builder". The FP side is portraying these venerable OOP constructs as if they were crude siege weapons, symbolizing how FP enthusiasts sometimes view OOP techniques as clunky or archaic compared to their sleek algebraic tools.

The humor here comes from the paradigm tribalism on display. Each side idolizes its own abstractions as if they were sacred relics and belittles the other's as if they were barbaric relics. This mirrors real-world tech debates, albeit exaggerated to fantasy extremes. Seasoned developers have seen these "holy wars" play out: the FP folks might snicker that OOP patterns are unnecessarily convoluted – "Why create a Strategy class hierarchy when a simple higher-order function would do?" or "Why need an Adapter when you can just transform data with a pure function?" On the flip side, OOP practitioners might roll their eyes at FP jargon – "You're introducing Monads and Functors to solve a problem that I can handle with straightforward classes and interfaces? Quit speaking in riddles and just write readable code!" Each camp tends to view the other's approach as overcomplicated in its own way: FP's abstractions can feel like ivory-tower math puzzles, and OOP's design patterns can feel like ceremonial engineering rituals. The meme exaggerates this by literally using slanderous adjectives: calling semigroups "glorious" versus builders "brutish" is like hearing two rival fan clubs or perhaps two medieval armies singing about their noble lineage while slinging mud at the enemy. Anyone who’s browsed programming forums has seen threads devolve into this kind of name-calling (minus the medieval phrasing). The meme distills that experience: it's monads vs. design patterns, each in its castle, convinced the other side lives in the dark ages.

Deep down, this castle standoff highlights how each paradigm solves similar problems with very different tools. Both sides care about composition and reusability, but they express those ideas differently. The FP side uses algebraic structures: e.g., a monoid gives a principled way to "add" or merge things, and a monad gives a disciplined way to sequence computations. The OOP side uses pattern-based structures: e.g., a builder organizes how to assemble an object, and a strategy organizes how to swap behaviors. To someone steeped in FP, many classic design patterns feel like reinventing wheels that mathematics already covered. (There's a famous observation that many GoF design patterns disappear or become one-liners in languages that support closures or higher-order functions – for instance, the Strategy pattern is trivial when you can pass functions around as first-class values). Conversely, to an OOP veteran, the FP approach can seem foreign and impractically abstract: why invent a whole new vocabulary (monoids, functors, etc.) instead of using plain objects and methods that everyone on the team can understand? The culture gap is real – and the meme milks it for comedic effect by pretending these are two medieval cultures in a literal shouting match. It’s funny because it’s both absurd and a little true: developers can get surprisingly passionate (even pompous) about their chosen paradigm, almost as if defending a kingdom.

This exaggerated standoff also nods to the difficulty of bridging the two worlds. Notice the two small boats in the river between the castles (one with a purple sail, one with an orange sail). They hint that communication or exchange is happening, but it's tiny and tentative compared to the mighty towers. In practice, there are bridges between FP and OOP ideas – modern languages like Scala, Kotlin, or F# try to mix functional and object-oriented features, and concepts from one paradigm often inspire improvements in the other. (For example, Java adopted lambda functions and streams, bringing a bit of FP flavor to the OOP realm, while Haskell borrowed the concept of TypeClasses which in some ways play a role similar to interfaces in OOP). Those little boats might even cheekily represent specific multi-paradigm technologies or merely the few brave souls who try to learn both paradigms and get them to trade knowledge. But compared to the grand scale of the castles, the meme suggests that these efforts are small in the face of staunch paradigm loyalty.

In summary, at this deep theoretical level, the meme is a comedic depiction of a fortress standoff between two intellectual traditions in programming: one side wielding the precise language of mathematics (algebraic structures like monoids and functors) and the other wielding the structured patterns of software engineering (factories and adapters). It's like watching a Category Theory crusade meet a Design Pattern stronghold. The result is hilariously over-dramatic: each side regards the other’s cherished constructions as nothing short of heresy. Only in the programming world do you get battles where the weapons are things like “Monad laws” versus “Factory patterns,” and this meme captures that absurdity brilliantly.

Description

Cartoon split into two castle-lined hills facing each other across a river. Left heading: "OUR BLESSED FP"; right heading: "THEIR BARBAROUS OOP". On the functional-programming hill, banners point to stone towers labeled "OUR GLORIOUS SEMIGROUP", "OUR GREAT MONOID", "OUR NOBLE MONAD", and "OUR HEROIC FUNCTOR". On the object-oriented side, mirrored banners point to towers labeled "THEIR PRIMITIVE FACTORY", "THEIR BACKWARD BUILDER", "THEIR BRUTISH ADAPTER", and "THEIR WICKED STRATEGY". Two small boats with purple and orange sails sit between the shores. The humor contrasts algebraic FP abstractions with classic OOP design patterns, parodying paradigm tribalism familiar to veteran developers

Comments

51
Anonymous ★ Top Pick After two decades of paradigm crusades, it turns out the moat between the FP and OOP castles is just a shared mutable Map - everyone’s been ferrying side effects across it in little boats named “abstraction.”
  1. Anonymous ★ Top Pick

    After two decades of paradigm crusades, it turns out the moat between the FP and OOP castles is just a shared mutable Map - everyone’s been ferrying side effects across it in little boats named “abstraction.”

  2. Anonymous

    After 20 years in the industry, you realize both camps are just trying to manage state and side effects while pretending their abstraction layer doesn't leak - the only difference is whether you call it a 'monad transformer stack' or a 'dependency injection container'

  3. Anonymous

    This perfectly captures the irony of FP evangelists who've spent years wrapping their heads around monads and functors, only to realize they've essentially reinvented the same design patterns OOP developers have been using all along - just with more intimidating mathematical names and a superiority complex. Both sides are building castles on the same conceptual foundation, but one insists on calling their bricks 'algebraic data structures' while mocking the other's 'primitive factories.' The real joke? Most production codebases are pragmatic hybrids that would make both camps equally uncomfortable

  4. Anonymous

    Most GoF patterns vanish once you have higher-order functions; what remains is a monoid, renamed 'builder' to pass enterprise architecture review

  5. Anonymous

    After 20 years, the FP - OOP border is mostly naming: their Builder smells like a Monoid, their Adapter like a Functor, their Strategy like a Monad - the ferry between castles is just called compose

  6. Anonymous

    FP functors fmap to victory; OOP builders construct yesterday's architecture one primitive at a time

  7. @moosschan 1y

    I miss the times, when programming was fun (it never was)

    1. @RiedleroD 1y

      talk for yourself, I'm having fun

      1. @azizhakberdiev 1y

        define fun

        1. @RiedleroD 1y

          No

          1. @azizhakberdiev 1y

            exactly

            1. @RiedleroD 1y

              No

            2. @RiedleroD 1y

              ok, now that I can actually reply instead of just pressing "reply no" on my watch, here's my actual point: no

              1. @RiedleroD 1y

                jokes aside, I just like programming. there's nothing more to it

                1. @azizhakberdiev 1y

                  like just coding and seeing it works or all that fuckshit with optimization, debugging and SDLC?

                  1. @RiedleroD 1y

                    depends on mood

                    1. @RiedleroD 1y

                      sometimes I really want to optimize a small piece of code into oblivion, sometimes I want to make a script that automates some work for me, sometimes I want to fix a bug in someone else's software …

                  2. @niko2048 1y

                    it's cool to just make stuff. Jobs suck because you dont care about what you're making often

              2. _ 1y

                Did you try the MesageEase keyboard to write messages from your watch ?

                1. @RiedleroD 1y

                  idk what that is, and I don't have one of those crappy apple watches or wearOS watches

                  1. @RiedleroD 1y

                    I have a pebble. no touchscreen. just four buttons. and I'd never change it for anything with a touchscreen

        2. @zexUlt 1y

          #define fun

          1. @SamsonovAnton 1y

            fun meme(dev: Int = 0): Int = dev / 0

    2. @pyrothefuck 1y

      it was fun until it turned into a job

    3. アレックス 1y

      Remember when we had opinions about languages?

      1. @RiedleroD 1y

        yeah I think austro-bavarian is just better than standard german … wdym … wdym that's not what you meant?

        1. アレックス 1y

          So true

  8. @nicovillanueva 1y

    A colleague once said, "I hate working as a concept". Principal eng, likes solving problems and stuff, but hates the whole risk management aspect of it, liaising with teams, bringing up legacy stuff, etc And, like, yeah, agree. I miss coding for fun. My work coding leaves no time for my fun coding.

  9. @EmberFox 1y

    Y'all are writing code? I'm just describing what changes I want to an AI and verifying it did what I said

    1. @RiedleroD 1y

      bad dev :bonk:

      1. @EmberFox 1y

        Mmm, I agree, but it's what makes sense for the business

        1. @RiedleroD 1y

          technical debt disagrees

          1. @EmberFox 1y

            Code doesn't need to be readable by humans if the AI can understand it /s

            1. @RiedleroD 1y

              not that, I meant accumulating legacy cruft and bugs

              1. @EmberFox 1y

                That's where the code review is key

                1. @RiedleroD 1y

                  you mean the code review that people like doing with chatGPT? or the one where they just gloss over it quickly without really giving it much thought?

                  1. @ZgGPuo8dZef58K6hxxGVj3Z2 1y

                    Copy, Paste, 1597668 rows affected, Move into a different country

                  2. @RiedleroD 1y

                    tbh code review is the one thing where AI can actually help. asking it "are there bugs or performance concerns in this code" could 100% be helpful

                  3. @EmberFox 1y

                    No, I mean manually reviewing the code and deciding if it's human readable (eg, not a ton of logic stuffed in one line)

                2. @EmberFox 1y

                  The state of code writing AI (Cursor) at the moment, seems to be basically a very fast junior dev. You tell it what it needs to do and it will do that, but sometimes makes wrong assumptions about how to structure the code or function definitions or whatever

    2. @ZgGPuo8dZef58K6hxxGVj3Z2 1y

      It barely can help in non general questions

      1. @EmberFox 1y

        I'm using Cursor and it's frighteningly good at reading and understanding existing code

  10. @EmberFox 1y

    Last week I needed to add a column of data to a reporting tool in The Legacy Code, and it was able to understand that spaghetti and make the changes after one prompt

    1. @ZgGPuo8dZef58K6hxxGVj3Z2 1y

      Ask it to make use of the codeGeneration capability in UWP. It will use wrong function signatures

      1. @ZgGPuo8dZef58K6hxxGVj3Z2 1y

        Microsoft doesn’t have samples of that (yet? ever?) and it cant come up with anything thinkable of its own. And it 1:1 copies sample code from a whole other SDK which have mismatching signatures

  11. @EmberFox 1y

    It even inferred that it needed to update the SQL query to get the data

  12. @EmberFox 1y

    shitty future fr

  13. @EmberFox 1y

    My boss was playing with some system that has different AI models working together to translate, write, and test code like a virtualized team, but I'm not a fan

  14. @EmberFox 1y

    My use case is not having to spend an hour+ reading the spaghetti code other people wrote 7 years ago just to make a simple change

  15. @maggi_increment 1y

    Which FP language Is good to learn?

    1. @RiedleroD 1y

      farming /j

Use J and K for navigation