I don’t know what the hell I’m doing here.
I thought I’d get that out of the way right at the beginning, because it will be obvious anyway.
I was inspired to do this by Larry. Wall, that is, inventor of Perl. Everyone’s favorite Evil Linguist.
Perl is the first postmodern programming language – A link here will convince them I’m not completely nuts.
I’m doing this while listening to some Beastie Boy-knockoffs on Radio Free MSU-N, where it’s always amateur hour and nobody quite knows how things work.
KNMC is the kind of station that plays a Brak story right after hip-hop and before some incomprehenisble 90s AltRock. It also plays oldies: This afternoon, it played an Elvis album into the freaking ground, over and over and over.
KNMC is also an NPR repeater. When it has nothing else to do, it apes NPR at a lower fidelity and in mono. So you don’t confuse it with the Real Thing. All Things Considered, it beats dead air. Except when NPR is playing a lugubrious string concerto that is the aural equivalent of oral codeine.
Now for something completely different.
I tend to move through languages in odd ways, driven by manias and brief spurts of heightened concentration to learn something utterly novel and theoretically interesting but generally useless (mainly because it is so wrapped up with its own interesting bits it neglects to do anything with them).
Forth is, by and large, one of these langauges: The stack is an amazingly powerful tool, something that can allow programmers to do a lot with a little, but unless you are willing to completely retool your mental transmission you’ll never be quite as natural in it as you’ll be in C or Perl or another algebraic language.
Example Forth code:
# this is a Perl-style comment. Not part of Forth :) 5 6 + . # this is input 11 ok # output from the interpreter : ++ 1 + ; # define a word ok 5 ++ 7 * . # confused yet? 36 ok # i'll stop. ( Forth comments look like this. )
Forth is great at being a small language for small systems, but it doesn’t scale well. Here’s something that should raise warning bells: Forth really shines as a development platform when the system’s OS is a Forth interpreter and the programmer is willing to mix Forth and assembly to get the fastest results. Needless to say, precious and few are the systems Forth dominates in that way. It’s pretty much embedded systems now, the only ‘small systems’ left in the world.
Lisp is the next language I’m into. Lisp is based around the lambda calculus, something that abstracts math into the pure ether, then spins the ether into recursive cotton candy around the notion of functions. Lisp is known to the C hackers who wonder who in the hell would need a machine devoted to their language as Lots of Irritating, Superfluous Parenthesis. Of course, everything is irritating until you grok it. The idea of emacs was irritating until I grokked the fundamental brilliance of doing your text editing in a development environment: Everything is text, so why not have the tools to do everything right there?
Hell, that even made sense: Emacs is an ELisp development environment. Mixing a discussion of emacs with Lisp is like mixing a discussion of duct tape with a discussion of warts.
;; A Lisp comment. (+ 5 6) ; input 11 ; output (defun inc(x) (+ x 1)) ; create a function defun (inc (+ 5 (* 8 (+ 2 3)))) ;Nest to your heart's desire 46
Forth is RPN (aka suffix), Lisp is prefix.
Forth disposes of all notions of grouping by making the order of operations explicit. Lisp goes hog-wild with grouping by requiring parenthesis around everything.
Forth is the interpreted, rapid development language for extremely small systems. Lisp is the interpreted, rapid development language for much larger systems.
A Forth machine would be a microcontroller in your fridge. A Lisp Machine was the biggest freaking ‘workstation’ of its era.
Forth is Modern. Lisp is Modern.
Modern languages have a central principle, a core idea around which all else hangs. Forth’s idee fixe is the stack. Lisp’s is not parentheses (bad jokes aside), but the lambda calculus. Both languages make the programmer conform to that basic idea.
Both languages are mummies, preserved by enthusiasts and niche applications.
Perl is the first postmodern language because Perl’s motto is TMTOWTDI (There’s More Than One Way To Do It). Perl is the first postmodern language because it refuses to take a firm stand on doctrinal issues. Perl is the first postmodern language because it conforms to you, not the other way around.
Perl is a vibrant, living language, living on in thousands of actively developed programs and cultures.
This is bizarre. I fucking came full circle without realizing it.
And now nobody will read this. Oh, well.