The Golden Age of BASIC (2014)
spectrum.ieee.org
spectrum.ieee.org
The computing era of the 1950s-1980s is interesting in that it was assumed as a matter of course that in order to get the most out of a computing system, users would write programs for it. As a result, the systems were fairly programmer-friendly and provided programming languages and instructions for using them in the box, including materials aimed at beginners.
Now that there are zillions of prefabricated apps that you can download almost instantly, there's a whole lot you can do with a computing system without ever touching a programming language. As a result, systems like macOS/iOS/Android/Windows are designed to create app and game users/customers rather than programmers or engineers - educational micro platforms like Raspberry Pi, Arduino, and micro:bit being notable exceptions, and Linux largely retains its programmer-oriented Unix heritage.
It's too bad, because JavaScript is included in every web browser, other languages like Python, Java and C++ are readily available for free on nearly every system, and even BASIC itself is still available from Microsoft in forms such as Visual BASIC, VBA, and SmallBasic. (And there are free and web implementations as well.)
What seems to be missing from iOS, Android, macOS, Windows, ChromeOS, and web browsers is an easy, visible, built-in onramp to programming. For example, Swift Playgrounds is neat, but I expect most iOS and Mac users don't know it exists, and would probably have little interest in it if they did.
I think Python is easy to use as a scripting language thanks to the proliferation of libraries, meaning that you can get things done without touching the obscure stuff. Many users can be quite productive with precisely the subset of Python that's not too different from BASIC. Python adds features faster than I can learn them, and though I'm a productive user, I scored "average" on a skills test.
Still, I'm going to take a refresher course next year. I don't want to be the guy who's teaching Python without knowing it.
But when you get to structuring it whole thing feels quite hacky and weird in places. Like why do I have this empty file here(__init__.py). Or what is the whole point of this "__main__" thing. Two examples of most basics ways of building a more complicated program and both are quite weird.
Back then, the screen was a playground one could poke and prod—without distraction, with a singular focus. This is especially important for children. Now we’re competing with the nearest iThing.
I always think of the parents who buy their children the latest-and-greatest toys, only to find their child is more interested in the box. Or perhaps a stick and some bugs in the back yard.
If you could read from a keyboard, write to the screen, and load and save files, you could already do everything that almost any commercial software could do.
Going from that to more modern systems (even Windows 95) was a giant change. So many libraries, frameworks, and systems to know about. And you need to know them and work with them in order to create anything remotely like a commercial program. Your programs don't have full control of the entire system.
So yeah, there's a lot more stuff available now, lots of free languages and tools, etc. But it's also a whole lot harder to get into.
When typing stuff on Darthmound BASIC, the instructions would be compiled straight into machine code while on the REPL, just like Lisp and co.
This topic comes up on HN from time to time and people often cite Javascript, Processing, Pygame and others as counterexamples, but none of these are remotely as accessible nor as simple to get going on as these crude BASICs were.
I would argue the problem is, back then, as a kid, you most probably had access to only one machine, and one PL. Now too many choices can make learning unfocused
Whereas when I entered "SET(1,1)" on a TRS80 model-I and got a single white pixel on the screen? That was some Magic, let me tell you.
Maybe the difference is that today it's harder to get the feedback between I-typed-this and that-happened, when there's already a whole lot of that happening all over the screen.
For a kid in 1980, there was a definite dopamine hit to be had from discovering the trail to High Technology, right there at your command. You could make Pong! Or Space Invaders! The possibilities were endless.
Kids today want to make the kind of games they play. Except that’s not really possible of course. Roblox, youtube, that’s the kind of thing they can actually do _and_ is the future as they see it. Poor kids. Robotics is the edge I’m trying to push; better than that other crap at least.
ABCDEF
GHIJKL
MNOPQR
Then you had to calculate the which character held which pixels and then alter the bytes inside that character to alter the exact pixel you wanted. So a pixel at 7,7 would be inside the A but a pixel at 10,10 would be inside the H.
(This is in some ways even worse than assembler, which usually has labeled goto’s.)
When I programmed in Basic those many years ago, I was stalled when my programs reached a certain level of complexity. I was then mostly halted in my education and development as a programmer for many years, because the language did not make program composition easy. It was not until I had the opportunity to learn other languages with did have proper functions and other methods of program composition that I could break through the barrier, so to speak.
(Reportedly, BBC Basic on the BBC Micro did have proper named functions, and later versions of Basic like on the Atari ST and Amiga also had them. I believe that those versions of Basic would have been vastly more productive and taught people the usefulness of abstracting things as you go, building ever higher abstractions, etc. But this is never the version of Basic which people talk about, or used by all those listings in magazines, etc. These are, for all intents and purposes, not the “80s style Basic” which everybody remembers with such apparent and baffling fondness.)
(Mostly a repost of previous posts of mine, e.g. https://news.ycombinator.com/item?id=25014279)
None of those early ones had a proper editor. It struck me sometime after leaving BASIC, that the whole line-numbering thing was really kind of a cheesy substitute for proper text editing. Given the limitations of the day, though, it was adequate. But relating to your point, once your program grew beyond a screen-full, you were stuck typing things like "LIST 300-399" several times a minute, just to look through your code. Today we just page-up/page-down w/o thinking, it doesn't break the flow just to navigate through a program, but in 1980, those line numbers were In Your Face!
For programs that fit on one screen, though, this wasn't such an issue. With something like the PET, you could even cursor around on the screen and change things almost like using Notepad.
The Basic compiler on DEC PDP’s had Function and Sub and modules you could swap in and out of memory as needed. PDP usage was huge in the 80’s. And Microsoft BASIC 7.1 was a full native compiler with the same language syntax.
The line number versions of BASIC were used for amateur code, but professional systems had full procedural syntax.
I remember using BASIC-PLUS on a PDP-11 running RSTS which I think could manage 20 terminals but the PDP-11 has the serious limitation that user space had a 64k address space just like a micro. This was a line number oriented BASIC like a micro BASIC.
My high school had a VAX which also ran BASIC-PLUS but they taught intro programming with PASCAL and also had FORTRAN. I don’t remember that basic being procedurally oriented (other than GOSUB) but eventually DEC came out with VSI BASIC which let you write procedures and functions that you could link into libraries and call from other languages.
I didn’t find this lack of abstraction a hindrance. It actually helped when I moved on to C on a PC. So I don’t find the fondness for the limited 80s BASIC baffling at all.
GfA BASIC, widely used on the Atari ST in the late 1980’s, and later also available on Windows (with a compiler, even), didn’t suffer most of the limitations you mention. It was a great and modern (for the time) language.
See the screenshot on Wikipedia for an impression: https://en.wikipedia.org/wiki/GFA_BASIC
You would edit code with a text editor and transform it into a program you run with the normal interpreter.
I rewrote it for the CoCo which was not very hard because the syntax of BASIC is simple enough that you don’t really need to understand how compilers work to make something like that.
You could learn the entire language, every keyword, by heart. You could get to grips with all the various basic logic flows (if then else, while), understand variables, and you could get instant feedback (essential for the young kid). Scratch provides that learning place now, but basic was good for that first step into programming.
Fully agree that it was easy to outgrow it (at least until things like quickbasic came along).
When I learned C in the 1980s, programming with strings was always a mess and produced a rich bounty of bugs. When initially designing the D programming language, I resolved that D wouldn't be any good until D did strings as easy as BASIC did.
And so strings are easy and bug free in D, and have become a great strength of D. Thanks to BASIC!
Those were the days of typing it in from a listing printed in a book or magazine. 16K of RAM was plenty, because any BASIC program more than 100 lines long was simply incomprehensible w/o some cheat sheet notes on the side.
About the most interesting thing that could be done with those machines was to learn the assembly language for the underlying processor. People said that assembly language was going extinct even in 1980, that it was a step backwards, but BASIC didn't seem to be the way forward, either.
Recalling fondly now the sheer delight of that first university class in Pascal.
https://www.dartmouth.edu/basicfifty/basicmanual_1964.pdf
The goals on page 1 are particularly relevant: 1) easy to learn, 2) efficient/compiled, 3) stepping stone to more advanced languages (s/Algol/Pascal/), and 4) general purpose.
This simplicity paid off for early microcomputers and microcontrollers which could fit a BASIC interpreter, hardware drivers, and a user program into a few kilobytes of memory, creating a system that could run any of the programs in the above Dartmouth BASIC manual.
RISC type processors can usually store the return address in a register and jump to an address stored in a register. On ARM you can also do an x86-like return with pop {pc}.
Many large programs such the first Unix kernel, and many video games, were written in assembly language.
My experience is that assembly language seems fine when you're writing it, but it's a pain when you go back some months later and try to read it. Good structure and comments help. I just read and wrote some RISC-V assembly language and it wasn't terrible, even though I'd never used RISC-V before. Writing assembly language makes you appreciate why (and how) programming languages exist.
That left no room for error messages. Hal proudly showed me his solution. It was one error message for all errors:
EH?
consuming only 3 bytes! WHAT?
HOW?
SORRY
What a difference 4K made!These ranged from the same experience as the Beeb to full functioned text mode IDEs.
Visual Basic from the Win95 era might be the best scripting language to write desktop gui applications that there has ever been.
10 sys(2063)
.. or the like? Yeah, clearly there were Mysteries that needed solving!It just begged you to use PEEK and POKE, to get at the real goodies. In a way this was an almost ideal precursor for learning assembly language; PEEK and POKE got you used to the idea of loading and storing things to memory or device registers, and then when you loaded up Jim Butterfield's SuperMon (thanks, Jim, wherever you are) and started banging around under the hood, heck, there were LDA and STA, ready and waiting. But a zillion times faster!
There's a scene in Stranger Things where Sean Astin's character tries to brute force a code using a basic variant, and it was surprising to me to see code on a popular TV show that was remarkably faithful to the original.
There is so much more power and information available trivially now, but we have come to expect that.
Back then, if it wasn't in a written manual, there typically was no other source of information. But that didn't stop us! We simply had to tinker with it, reverse engineer it a bit. I think that was a big part of what made it special.
Endless hours exploring that thing, typing commands, bending the computer to your will (and possibly learning some assembly along the way).
Until, I rekindled my interest in electronics more than 30 years later. Many of the affordable quality test and measurement instruments, read old ones, come with examples on how to control them via GPIB using BASIC (a variant of Rocky Mountain Basic afaiu). -hp- was big on BASIC. First their minis, then their 'calculators' and even the work stations. Those short examples in the manuals are easily translated into Python today, but sometimes I wished I had a RMB available for Linux.
https://archive.org/details/tibook_beginners-basic
https://archive.org/details/tibook_users-reference-guide
From BASIC, it gives you variables, control flow, keyboard reading, addressable character cell graphics with color and custom characters, and multi-voice sound. You can do a whole lot with that, and that was the book you opened when you plugged it into your TV and started figuring out what you could do with this thing. (I wanted to make video games, and I did.)
Later, in high school, we had a PDP-8 with DEC EDUsystem BASIC on it, later replaced with a small PDP-11. This was right around the time that Apple ][ and TRS-80 were just appearing on the scene. Until then, programs were entered on printing terminals like Teletypes, GE Terminet, and DECwriter II.
This is not that long ago, in a relative sense.
https://jugad2.blogspot.com/2012/09/lissajous-hippo.html
And a related HN comment by me that may be of interest because of the mTCP stack that Mike Brutman developed for the IBM PC Jr.:
The Golden Age of Basic - https://news.ycombinator.com/item?id=7680045 - May 2014 (11 comments)
AOT compilation, with managed languages on top of COM, in a sense bringing back VB 6, and an approximation of C++ Builder.
Then management messed it all up.
These days, when I want to build cross platform desktop apps quickly, Lazarus is #1 choice.
P.S: I don't write desktop apps profesionally anymore, used to write a few in Java Swing and FX.
There's an exception. And that's the BASIC dialects. I don't have very much fondness for it, even calculating for nostalgia.
I wouldn’t wish GOTO/GOSUB on anyone, but the latter procedural versions of BASIC were very productive tools.
However, the big emphasis was on Logo in primary schools at my time.
Speaking of which, does anyone know of a MSX-Logo English version ROM available for download? Can only find it in Dutch...
As a side note - AMOS on the Amiga was awesome, and PDS on DOS (with SVGA libraries) both me to start my first business when I was 15 (through-the-window real-estate listings). Even then the shame of being a basic programmer stayed with me, I would deliberately compress, use a 3rd party linker & hex edit the beginnings of compiled programs (on PC) to ensure nobody could work out that I was using compiled QBX (quick basic). I continued with VB, Blitz and the like until learning C# with Unity... then I felt the shame of not being able to do the equiv. of 80's assembler (shader programming).
Perhaps one day I'll get over myself and believe I'm not a lamer at heart :-)
I often think I was born a few years too late, things moved so quickly and I was a bit too young... TRS-80 -> Amstrad -> Amiga by the time I was 14 - and the Amiga was really complicated with it's custom chips.
Anyhow. Just a bit of a rant ;-) Thanks for reading.
p.s. Oh, just thought I'd add that I also played with RISCOS and BBC Basic during the period mentioned above and was blown away by how all the OS functions and so on were exposed to BBC basic, for me, this has always been the problem with Basic variants. Doing SVGA graphics on the PC with QBX required 3rd party libraries, proper TCP/IP under VB required IP/Works, and so on... back then I was always struggling - not with optimisation - but with access to features I needed that weren't offered through whatever dialect of basic I was using. BBC Basic on the other hand seems to be done right, I expect you could write any application you cared to without resorting to C or assembler.