The Lost Ways of Programming: Commodore 64 BASIC

This article is nothing new for the readers of this forum, it’s more of a introduction to the old ways for the people accustomed to the modern ways, but it nicely has gotten the idea of the lost approach to programming, the immediacy of it: The Lost Ways of Programming: Commodore 64 BASIC

2 Likes

That was more fun than I thought it would be… oh, old times. The reason I wasn’t sure that would be fun is that these days the only thing I remember about BASIC is how much I disliked it. But that’s something which happened when I ran into its limitations, which I later found was called “lack of structure”. One can see a small issue running up even in this demo:
2080 IF Y=25 THEN DY=-1
2090 IF Y=25 THEN Y=23
2100 IF Y<0 THEN DY=1
2110 IF Y<0 THEN Y=2
Not even a simple block, so the IF tests have to be repeated in order to do more than one thing.
But it was a fun exercise nevertheless.

Some BASICs allowed multiple statements on one line separated by a colon. This allowed small blocks after a THEN like this:

2080 IF Y=25 THEN DY=-1:Y=23
2100 IF Y<0 THEN DY=1:Y=2

There were also BASICs with IF/ENDIF and other structured control flow, which combined with line numbers being optional made it more into an awkward Pascal than a BASIC. This reached its extreme in Visual Basic.

That’s the common problem with “BASIC”: it was a spectrum of implementations across a multitude of platforms. So when people say “BASIC did not” or “BASIC did”, or “BASIC was”, or “BASIC was not” you can argue yes and no and maybe. (Personally, I for example cannot bring myself to call Visual Basic a BASIC anymore, Microsoft made it in its own image.)

One thing I find quite nice about the linked page with the embedded C64 in it, is that it’s a very loose emulation indeed - as noted, the Basic in there doesn’t even have FOR NEXT. And yet, from a demonstration and teaching point of view, it very much gets the job done. There’s a place for super-accurate emulation, and it turns out there’s also a place for broad workalikes. The emphasis here is on the teaching, and the story, not on the technology. And the takeway is that an interactive programming environment is empowering.

2 Likes

A post was split to a new topic: On the merits of cassette tape for data storage

I think this is just human nature. Look at what happened to Latin, for example!

Before the Internet and shared Github repositories it was just easier to do your own thing. Basic was pretty uniform compared to Forth or Lisp. Even the two most popular implementations of Pascal, UCSD and Turbo, required quite a bit of rewriting to move programs between them.

Even with lots of money and strong organizations like those behind Fortran and Cobol it was not possible to keep people in line. Having studied a port of the Berkeley Spice program from CDC6600 Fortran to PDP-11 Fortran I can tell you I had a much easier time porting from Microsoft Basic to Sinclair ZX81 Basic.

But it can be annoying if one Basic interprets my example above as

IF Y=25 THEN {DY=-1:Y=23 }

and another thinks it means

{IF Y=25 THEN DY=-1}:Y=23

I am not complaining about the diversity or the progeny, on the contrary, I’m praising it! Mainly I meant that what various people experienced as “the BASIC”, varies, and that many statements about BASIC should be taken by a large helping of salt because of the nebulosity of the subject.