[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]

>procedural >functional >OOP >imperative which should

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: 2

File: 1490555694139.jpg (31KB, 601x508px) Image search: [Google]
1490555694139.jpg
31KB, 601x508px
>procedural
>functional
>OOP
>imperative

which should I learn?
What good sources are there about the diferences?

Why OOP is bad?
>>
>>59604800
go with imperative if you're writing performance-crucial shit like a pixel shader or something. It means hand-holding your cpu on what to do and using virtually no abstractions

procedural i've always found to be kinda unidientifiable, like how the fuck do you recognize something to be procedural

functional is much nicer, more readable and such than oop, but inherently it's stateless, which makes certain things very difficult to implement. Don't try making a chess game or something in functional, it'll be a horrid mess you can't make sense of because the game's state isn't defined well. Use functional for a sort of transformation pipeline, where some data comes in, you apply some transformations to it, and output something related (e.g. maybe you can implement a binary hash program in it, hashes are usually transformation pipelines with little or very transient state)

oop for anything that's gonna be inherently stateful like a game, stuff with databases like a sales/clients register, and guis
>>
>>59604800
oh btw java is a nice mix of both oop and functional

>inb4 pajeet

java is all about oop, but you have streams and lamdbas, so inside a code body somewhere you can do things like
Map<identity, thing> map = listOfStuff.stream()
.filter(x -> x.someBooleanProperty())
.filter(x -> "bla".equals(x.thing))
.map(x -> new WrapperThing(x))
.collect(x -> Collectors.toMap(x.identity, x));
>>
>>59604937
>Map<identity, thing>
*Map<identity, WrapperThing>
>>
>>59604937
>oh btw java is nice
AbstractBeanFactorySingletonBuilder
>>
>>59604800
OOP is great, it's just that most people don't know what it really is
>>
>>59604997
so don't be a RetardedMonkeyBasedCodeWriterImplementation
>>
File: OOP.png (552KB, 1936x5960px) Image search: [Google]
OOP.png
552KB, 1936x5960px
>>59604800
>Why OOP is bad?
Because people are retarded and can't design shit
>>
>>59604871
>procedural i've always found to be kinda unidientifiable, like how the fuck do you recognize something to be procedural
If it has procedures, it's procedural.

Moreover, all of these paradigms aren't antagonistic to each other.
>>
>>59605051
so basically imperative split into blocks (functions)?
Thread posts: 10
Thread images: 2


[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.