4 ms·
> I understand the arguments against BASIC, e.g., ingraining impractical paradigms, The early interpreted BASICs did make it difficult to write good code. All
by mschaef 7y ago
> I understand the arguments against BASIC, e.g., ingraining impractical paradigms,
The early interpreted BASICs did make it difficult to write good code. All source editing was line editing, every line was numbered, there weren't any structured control flow statements, composite data structures were limited to arrays and strings...
But even as early as the second half of the 80's there were mainstream implementations of BASIC that addressed all of these. Microsoft QuickBASIC 4 added a full screen editor and then completely relaxed the need for line numbering. Line numbers were still supported, but so were symbolic labels. QB4 also had support for functions/subroutines, decent control flow statements, and structured data types. There was also reasonable support for extension libraries, and the like. As long as you didn't rely on any code patterns that required any kind of callback or inversion of control, you could do a very nice job writing well factored and maintainable code.
- smacktoward 7y ago> The early interpreted BASICs did make it difficult to write good code. All source editing was line editing, every line was numbered, there weren't any structured control flow statements, composite data structures were limited to arrays and strings... The sad part is that, because BASIC was supposed to be the "easy" programming language, it was frequently used as the language in which students were taught how to program. Which meant its bad habits ended up getting impressed hard onto a lot of impressionable minds. I spent years fixing all the ways first learning to program in BASIC had bent my brain.
- mschaef 7y agoI managed to avoid most of that, thanks to a bit of sheer, dumb luck. Back in the early 80's, my elementary school piloted a program (inspired by Seymour Papert, I presume) to teach school age children to program in Logo. So we had a lab full of twelve C64's across the hall from the Apple ][ lab and were taught to program in Logo. This included structured control flow, sub programs, recursion and the like. It was a far, far better experience than I imagine it would've been to be initially exposed to Basic. In retrospect, this is probably a big part of why, a few years later, I found some of the structured programming facilities of QB4 as appealing as I did.
- Someone 7y ago"The early interpreted BASICs did make it difficult to write good code. All source editing was line editing” You have to see this in historical context. That Basic had an editor was a huge step forwards. That it wasn’t a full-screen editor was because full-screen editors didn’t exist yet (who wants to wait for their teletype to print 24 lines, and waste half a page of paper on it?) https://en.wikipedia.org/wiki/BASIC#Origin https://en.wikipedia.org/wiki/BASIC#Origin: "The first version BASIC language was released on 1 May 1964” https://en.wikipedia.org/wiki/Text_editor#History https://en.wikipedia.org/wiki/Text_editor#History: "One of the earliest full-screen editors was O26, which was written for the operator console of the CDC 6000 series computers in 1967.”
- mschaef 7y ago> You have to see this in historical context. That Basic had an editor was a huge step forwards. That it wasn’t a full-screen editor was because full-screen editors didn’t exist yet I (mistakenly!) edited out the part of my post that clarified I was thinking of microcomputer implementations (77-83 or so). Of course, full screen editing was common then, even if not necessarily in the interpreted BASICs of the time. BASICA had a command to edit a line 'EDIT 120' that let you use an interactive line editor of sorts. (And C64 BASIC 2.0 could do something similar, I'm pretty sure). On the contrary, the contemporary Logo implementations of the time let you hit an F-key that dropped you into a full screen editor window with your source text. QB4 just started you off in the full screen editor with an immediate window (REPL, sort of) at the bottom of the screen.
- kentbrew 7y agoI did a ton of good work in QuickBASIC 4.5. Wrote some shareware games, one of which was converted to a successful commercial product. Plus lots of contracting in the 80s for people who needed data (send back and forth on floppies) converted from one accounting system to another.
- mschaef 7y ago> Plus lots of contracting in the 80s for people who needed data (send back and forth on floppies) converted from one accounting system to another. When I was sixteen or seventeen, I worked as a summer intern in the IT department of a local utility company. They gave me this data conversion task that they expected me to complete manually on a timescale of roughly the entire summer. It took about two days before I just automated the whole thing with a Turbo Pascal 6 program and had the task completed in something like a week. The biggest part of the challenge by that point was moving around a large volume of data (~100MB) on the 1.44MB floppies common at the time. (I remember ARJ helping immensely, between it's multi-disk support and the high compressibility of the data.) My unexpectedly high output on this task served me well.