[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

Why can't functional and OO programming get along, /g/?

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 10
Thread images: 1

File: FightingChildren.jpg (33KB, 673x473px) Image search: [Google]
FightingChildren.jpg
33KB, 673x473px
Why can't functional and OO programming get along, /g/?
>>
Both are meme tier
>>
>>57906797
They already do, it's just that the zealots of both sides refuse to recognize it. You just use objects to encapsulate and control state safely, and then use immutable constants and purely functional methods to manipulate that data from received state, only transforming state via message-passing to objects.
>>
>>57906950
Interesting, do you think Scala does this job well? Or is there any other language worth mentioning
>>
>>57906797
FP is made by academics who have never heard of encapsulation, polymorphism, compilers, loops, or real life. OOP is made by professionals who know what it's like in the trenches. If you think FP is worth wasting time on, obviously you've never killed a man.
>>
Because OO is garbage.

Functional is good for some tasks, mostly is just fun to do. OO is neither of these things. It's just awful outside of a theoretical nice idea point of view.
>>
>>57906972
I haven't ever used Scala. I use Lisp. You can do that kind of programming in any kind of multi-paradigm language, which is most of them these days.

>>57907045
When you use composition and mixins instead of overusing inheritance it becomes much nicer.
>>
>>57907214
You can't overuse inheritance. You're thinking of subtyping. They're completely different.
>>
>>57906797
>What is Python
>>
>>57906950
It sounds like you're basically describing monads with extra steps
Thread posts: 10
Thread images: 1


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.