Hacker News new | ask | show | jobs
by rbanffy 3511 days ago
The point is not being fast, but easy. BASIC has GOTO and GOSUB, IFs (which take the place of conditional jumps), no stack (that you can use yourself), no named functions (except branchless one liners) and a meager set of primitive types which are handier than the 6502 registers. Ever tried floating point on a 6502? Even with the routines in ROM, it was all pain and suffering.

I am sorry you had such a bad experience with BASIC, but, for teaching the very basics of programming, it was a useful tool. In order to teach assembly you'd need a text editor, an assembler and a floppy disk. BASIC came up when you powered your machine on.

I used Aztec C on the Apple II and, while it was painfully slow, it was a reasonable C for the time and, IIRC, it had a C64 version.

1 comments

To be specific, I'm talking about today and how BASIC is an anachronism, not unlike making your own natural pigments just to learn how to paint.

BASIC was nothing but bullshit, it taught me nothing other than computers are obnoxious and difficult to use. I spent several years "learning" how to program in BASIC, later QuickBASIC, and the stuff I cranked out was atrociously bad. The only excuse I have is that I was coding like they did in the magazines I bought, their code was a disaster as well, and I had no way of knowing there was a better way.

It was only when I switched to Pascal (via TurboPascal) that I realized how to program. At that point things started to make sense, and no longer was I feeling like a third class citizen: Programs in TurboPascal would run very quickly compared to BASIC. They were compiled. While the performance wasn't on par with C, it wasn't nearly as hard to get right as C was.

I wouldn't recommend Pascal today, but there's other languages that are as good or better.

Today there's absolutely no reason to teach BASIC as an introduction to programming. You're only going to hurt people.

Would you have realized how Pascal is better without struggling with BASIC first?
Would you have realized how C is better without struggling with machine opcodes first? Would you have realized how x86 is better without struggling with a 6502 first? Would you have realized how DRAM is better than struggling with drum memory first?

You can start anywhere if you like what you see and feel motivated to learn more.