2014-11-05-1132966

Using animals as an example (OO people love animals), define mammal and derive giraffe from mammal. Then define a member function mate, where animal mates with animal and returns an animal. Then you derive giraffe from animal and, of course, it has a function mate where giraffe mates with animal and returns an animal. It’s definitely not what you want. While mating may not be very important for C++ programmers, equality is.

https://www.sgi.com/tech/stl/drdobbs-interview.html

#programming #oop #quote

բնօրինակ սփիւռքում(եւ մեկնաբանութիւննե՞ր)

պիտակներ՝ programming  oop  quote