2 ms·
Replacing ifs with ternaries and switches with cond are hardly significant or important changes. The whole point of abstraction (functional or object-oriented)
by empthought 9y ago
Replacing ifs with ternaries and switches
with cond are hardly significant or important changes.
The whole point of abstraction (functional or object-oriented) is to push that logic from control structures in code to composition structures in runtime data.
If you weren't replacing conditionals with polymorphism, you weren't doing object-oriented programming in the first place.