Scott Sauyet
2/6/2016 3:10:00 AM
Aleksandro wrote:
> bit-naughty@hotmail.com wrote:
>> OK, I've read about and tried to understand OOP for a long time now,
>> but I don't think I really get it.
> I think that trying to understand OOP with Javascript's prototype-based
> method to make them is not a really good idea. I suggest you first learn
> C++'s.
I disagree. I would suggest that C++/Java/C# are among the *worst*
ways to learn OOP. Smalltalk would be better. Python or perhaps Ruby
might be acceptable, but more unusual OOP styles like Self or
Javascript would also teach a fair bit, as would a language that never
really claims to be object-oriented, but contains some of the best OOP
ideas: Erlang.
Of course, I'd suggest that learning functional programming is more
interesting still, and there's a whole herd of languages that support
FP. That list intersects with the OOP world in at least Javascript,
Scala, LISP (if LISP can be considered to match any of these
paradigms, when really it simply invented them and mixes and matches
them as it pleases :-) ), and, with the same caveats, Erlang. Many
other languages straddle the line a bit differently, falling mostly
into one camp, but with enough support for the other to be able to
claim some degree of membership.
But still, C++ to teach OOP? In 2016? I think there are many better
choices.
-- Scott