Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
*TRUE* OOP and Other Paradigms
#11
(04-04-2016, 06:25 PM)A-Man Wrote:  So it's performance vs memory. But the latter is usually way more abundant, so storage is what I'd try to stick with as well.
Wrong. CPU caches are a thing and because of that using little memory can actually be faster.
For more information: https://www.youtube.com/watch?v=rX0ItVEVjHc and https://www.youtube.com/watch?v=WDIkqP4JbkE.

(04-04-2016, 06:25 PM)A-Man Wrote:  What do you think of friends? Now that and encapsulation would be head-to-head in a way.
friend
is iffy at best. Whenever I use it I always feel kinda dirty, with the exception of operator overloading where the non-member variants are preferred.
Age ratings for movies and games (and similar) have never been a good idea.
One can learn a lot from reinventing wheels.
An unsound argument is not the same as an invalid one.
volatile in C++ does not mean thread-safe.
Do not make APIs unnecessarily asynchronous.
Make C++ operator > again
Trump is an idiot.
Reply
Thanks given by: A-Man
#12
OOP is good, but you can write a disaster even if all your code is pure classes...
The most important thing is too write code as simple as possible, that do its job well and is easy to understand.
OOP can help achieve these goals, but it depends on the case.

And I must mention the greatest "article" that was ever written about that :D
https://www.se.rit.edu/~tabeec/RIT_441/R...20Code.pdf
Reply
Thanks given by:




Users browsing this thread: 1 Guest(s)