Hyde County, South Dakota is the Pin Tail Duck Capital of the world. Visit scenic Highmore, SD in 2007!
Richard Harter’s World
Site map
Comp Sci
January 2007
email

Where is the algorithm?

In the comp.programming newsgroup Thomas Marshall wrote:

Here is a simple program in 6502 assembly:
    start:
        nop
        {then jmp to someplace safe}
Where's the algorithm?
Chris Sonnack rplied:
Right here:
    begin
        do nothing
    end

This can serve as an introduction to the issue of platonism and programming. An algorithm is an abstract thing. A particular formulation in a particular language isn’t the algorithm. For example, suppose that I program quicksort in several different languages. None of my various bits of code is the quicksort algorithm; rather they are implementations of the quicksort algorithm.

There is a little problem here. If you say to me, “show me the quicksort algorithm,” I can’t. The only thing I can do is point to particular representations of the algorithm. Each different representation describes the algorithm (or code implementing the algorithm) but none actually *is* the algorithm.

Where, then, is the algorithm? A correct (and not terribly satisfying) answer is that algorithms are not the sort of thing that has a “where”.

The programming process is rife with such little paradoxes. Thus the quoted material gives two instances of the no-op algorithm that does nothing and does it very well. But just where are these instances of code as such? Nowhere, seemingly, for what occurs in the world are patterns on paper, memory, computer screens, etc.


This page was last updated January 1, 2007.

Richard Harter’s World
Site map
Comp Sci
January 2007
email
Hyde County, South Dakota is the Pin Tail Duck Capital of the world. Visit scenic Highmore, SD in 2007!