3 ms·
VCF-80 Model 100 – a 'modern' take on the Tandy TRS-80 Model 100
- PaulHoule 3y agoReminds me of the time I coded up an FFT from scratch in BASIC on my Model 100 riding in a Greyhound across Vermont.
- rbanffy 3y agoIt's fun to think that BASIC is a pretty low-level language - all variables are of 3-4 primitive types, all are global, and there is barely anything that departs too much from the underlying metal.
- PaulHoule 3y agoIn some ways it is like assembly language: GOTO, GOSUB and such are a lot like branchex and jump. BASIC lacks: (i) subroutine scoped variables (ii) structures (like in C) and (iii) hashtables (like in Perl) (i) makes certain algorithms hard to code, for instance it is much harder to code a Quicksort in BASIC than it is to code a bubble sort or Shell sort. The pinnacle of advanced programming in BASIC may be these games https://en.wikipedia.org/wiki/List_of_Scott_Adams_Adventure_video_games https://en.wikipedia.org/wiki/List_of_Scott_Adams_Adventure_... which runs a strange interpreter that Adams wrote in BASIC that used arrays to emulate ‘objects’ like the lamp or the pirate ship: the game is just a set of data tables that can be loaded by cassette tape. Scott Adams later wrote interpreters in assembly for computers like the TRS-80 and Apple ][ that would play the same data. I wouldn’t mind writing tokenizers and parsers in BASIC precisely because these can be table driven and compilers often execute recursive algorithms with an explicit stack anyway.
- rbanffy 3y ago> compilers often execute recursive algorithms with an explicit stack anyway. Threading compilers shouldn't be too bad, but anything more complex would need a lot of extra work. I once implemented recursion using an array for a fake stack and the return stack for the "function", but it was a lot to wrap my then young mind around. I can no longer figure out how I did it.