
Object-Oriented Programming – The Trillion Dollar Disaster - fpoling
https://medium.com/better-programming/object-oriented-programming-the-trillion-dollar-disaster-️-92a4b666c7c7
======
boblebricoleur
>OOP is considered by many to be the crown jewel of computer science. The
ultimate solution to code organization. The end to all our problems. The only
true way to write our programs. Bestowed upon us by the one true God of
programming himself…

I've litteraly never met any one praising OOP like this. Even if the intent of
this introduction is to overly to make a point, I find it flawed.

> OOP attempts to model everything as a hierarchy of objects I never heard of
> anyone trying to use a hierarchy where it wasn't adapted

> The real world has no methods The real world needs to be modeled into
> something that can be computed by our human Mathematics. That's the whole
> point of modeling.

I'm waiting for the 'Functionnal Programming is wrong, let's go back to coding
everyting in asm' post in 10 to 20 years

------
wallstprog
"Those who do not learn history are condemned to repeat it".

I came up writing code in BAL, COBOL, PL/1 and a bunch of other non-OOP
languages, and those who think procedural programming is better have probably
never done it. The starting point for OOP, at least for me, was the splendid
book "Reliable Software through Composite Design" by Glenford Myers, which was
the first to study coupling, cohesion and other techniques that lead directly
to OOP. This book still maintains a position of honor on my shelf, and I
strongly recommend it for anyone doing software development. (You can get a
pdf from
[https://archive.org/details/reliablesoftware00myer](https://archive.org/details/reliablesoftware00myer)
or buy your own hard-copy at [https://www.amazon.com/Reliable-software-
through-composite-d...](https://www.amazon.com/Reliable-software-through-
composite-design/dp/0884052842)).

Now, crappy programmers can write crappy code in any language, just as good
programmers can write good code in any language -- the prevalance of crappy
code speaks more to the numbers of crappy programmers than crappy languages. I
would suggest that OOP enables crappy programmers to write code simply because
without OOP crappy programmers wouldn't be able to write any code at all.

When functional programming is able to provide performance on a par with non-
functional programming, we can talk about it. Until then it is a curiosity,
but not ready for prime-time.

To paraphrase Winston Churchill's comments on democracy: "OOP is the worst
programming paradigm ever invented -- except for all the other ones".

~~~
Buttons840
Doesn't functional programming already provide performance on par with non-
functional programming?

------
starchild3001
Yes,I get the criticism against OOP. I kinda don't understand how FP solves
the problem of shared mutable state... Or what alternatives there are for
myraid design patterns.

I coded in Scala for <1 yr. Loved its syntax and code cleanliness. Not sure if
I can do everything OOP does with pure FP, however.

~~~
fpoling
FP helps to avoid the mutable part of “shared mutable state” or at least
reduces it to the minimum.

Another pattern is linear or affine type system like in Rust. They helps to
avoid the shared part while keeping things mutable with ownership tracking.

------
asanz
OP seems to have ignored 2 issues

1\. Objective-C enabled Apple's productisation

2\. C++ programmer usually mix C code as well

------
jmkni
Paywalled.

~~~
fpoling
From Norway I can access this without any payments from a private tab.

