📓 object-oriented-programming.md by @ryan

object-oriented programming

There are, broadly speaking, two kinds of object-oriented programming:

  1. [[Smalltalk]]-like, which is similar to the [[actor model]].
  2. [[Java]]-like, which has more to do with [[inheritence]] hierarchies.

The contents of this page will mostly have to do with the latter. See the “actor model” page for Smalltalk-like OOP.

The holy trinity of OOP languages are [[C++]], [[Java]], and [[C#]].

OOP languages proper are characterized by framing every aspect of the program as a [[class]]. In [[Java]], there is a special class which must have a static method called main. Java and C#, until recently, did not allow for [[free function]]s.