mandag, januar 12, 2009

The Problem of Universals in Computer Programming
The problem of universals is originally a thread of philosophical discussions with its zenith in medieval times. A typical example of the issues discussed is the question whether the individual (ie. man) or the universal (manhood) is most real.

In computer programming the problem of universals is not in regard to understanding the nature of things, but relates to different methodologies one can apply in practically solving programming problems. As the old problem of universals were concerned with understanding what is already there, the new problem of universals deals with practicalities concerning the creation of computer programs.

Realists will always insist on making solutions that are universal: Every method, routine or piece of code must be created in such a way that it is possible to use it again for solving similar problems.

Nominalists (anti-universalists) maintain that a piece of code should only attempt to solve the problems it was originally intended to solve. It is unnecessary and a waste of time to try to solve all similar problems.


Nominalists will find that if they never try to write code in a universal way, they will have to write an awful lot of code, with a lot of repetition.
Universalists on the other hand, will drown themselves in universal pretensions unless they focus on the concrete issues to be solved.