@[email protected] to Programmer [email protected] • 2 months agoMy friend suggested I use different names for variables..lemmy.caimagemessage-square53fedilinkarrow-up1294arrow-down112file-text
arrow-up1282arrow-down1imageMy friend suggested I use different names for variables..lemmy.ca@[email protected] to Programmer [email protected] • 2 months agomessage-square53fedilinkfile-text
minus-squaremagic_lobster_partylinkfedilink1•2 months agoI like to mix between OOP and FP for different levels. OOP is great for higher architectural problems. FP is great for everything under it. And yes, inheritance was a huge mistake. Just use composition and interfaces instead.
minus-square@[email protected]linkfedilink3•edit-22 months agoYeah, I mix them too, although I apply quite a bit of functional techniques especially at the architectural level as well. OO I use mostly for dealing with I/O and other areas where statefulness cannot be avoided. If you’re interested, I also wrote an in-depth blog where I touch on these topics: https://arendjr.nl/blog/2024/07/post-architecture-premature-abstraction-is-the-root-of-all-evil/
I like to mix between OOP and FP for different levels. OOP is great for higher architectural problems. FP is great for everything under it.
And yes, inheritance was a huge mistake. Just use composition and interfaces instead.
Yeah, I mix them too, although I apply quite a bit of functional techniques especially at the architectural level as well. OO I use mostly for dealing with I/O and other areas where statefulness cannot be avoided.
If you’re interested, I also wrote an in-depth blog where I touch on these topics: https://arendjr.nl/blog/2024/07/post-architecture-premature-abstraction-is-the-root-of-all-evil/