HLUG TWiki > Main > SNOBOL ( vs. r1.1) TWiki webs:
AIX| Classes | HALBOD | HLUG | Helpdesk | Library | Main | Samba | TWiki |
Main . { TWikiGuest | Index | Changes | Search | Go }
 <<O>>  Difference Topic SNOBOL (r1.1 - 10 Jan 2004 - RickArchibald)
Added:
>
>

%META:TOPICINFO{author="RickArchibald" date="1073761537" format="1.0" version="1.1"}% %META:TOPICPARENT{name="RickArchibald"}%

SNOBOL

SNOBOL was the 2nd computer language I learned.  Here is a piece I wrote on the SNOBOL page at the original Wiki


It was probably 1966 when I last touched SNOBOL. I first "met" it in the fall of '64 in my first programming course. All these years later (2001) when I started learning GNU/Linux & got serious about using regex's, I had a strong sense of deja vu. Of course a little 'net research revealed the the genealogy of regex's, and I understood why.

Eventually I wrote a SNOBOL program for my Descriptive Linguistics course instead of a term paper. It was called "LINGEN" for "LINguistic GENerator", and its job was to generate random strings according to linguistic rules supplied by the user. The purpose was to allow the user to test his theories of linguistic structure by generatind N random samples, and then inspecting them for "nonsense" vs. "garbage". My demonstration was an examination of "clause" structure. It had "mouse", "cheese", "cat", & "dog" for the nouns; and "chased", "ate", "caught" among the verbs. This led to results like:

THE DOG CHASED THE CAT THE MOUSE ATE THE CHEESE THE CAT ATE THE CHEESE THE CHEESE CHASED THE MOUSE THE CHEESE ATE THE MOUSE not

CAT THE DOG CHEESE (btw, I am not yelling, just reminding you what output looked like back then.) You get the idea. However humorous, & I did pick the vocabulary with that in mind, the first 5 examples would be classed as "nonsense", while the 6th is "garbage".

In the process I got account "LNG001" at the computer center, this may mean that I was the first kid on the block to think of using computers for linguistics.

I too, had to design a syntax for the prospective user, to communicate his proposed ruleset to the computer without having to learn the whole SNOBOL language. My original goal was to get out of writing a full term paper, so I really didn't expect the program to used again. But a year later, with both professor's permissions, I re-did it and again submitted it in lieu of a term paper; this time for "History of the English Language". What I find most interesting is that about 5 years later, the the HotEL? prof. published an article in the Alumni Magazine on computer generated poetry. The program description sounded identical to mine, but article credited someone else with writing it. I have always wondered what really happened.

One of the other possiblely ground-breaking features of SNOBOL3 was automatic defragmentation. I have no idea if this a first for SNOBOL, but it may have been. Since it was working on a 36 bit word machine, 6 - 6 bit EBCDIC characters, the designers never wrote over stored strings: If a string was changed, they just wrote the new version in continuous (machine) words at the next available memory address and changed the pointer. When all their alloted mamory was used up, they ran a "garbage collector" which rewrote all active strings at the beginning of the string memory space, i.e. defragmented string memory.

Automatically.

Can Microsoft do that yet?

Another "feature" was integer only arithmetic. This made writing the LINGEN (pseudo) random number generator interesting...

Thanks for the chance to stroll down memory lane, I am another with a soft spot for SNOBOL.

-- Rick Archibald - 10 Jan 2004

http://www.adamsinfoserv.com/twiki/bin/view.cgi/Main/RickArchibald

Oops! I just noticed that the "minor edits" box resets each time... Sorry if I trashed the version history, I am more used to TWiki.


-- RickArchibald - 10 Jan 2004


Topic SNOBOL . { View | Diffs | r1.1 | More }
Revision -
Revision r1.1 - 10 Jan 2004 - 19:05 GMT - RickArchibald
Copyright © 2003-2007 by F. A. Archibald III & the contributing authors