3 ms·
Scheme is wayyyy simpler than Forth IMO (even when you include macros and call/cc). I wrote a minimal stack-based language years ago and I still cannot get a ha
by eatonphil 8y ago
Scheme is wayyyy simpler than Forth IMO (even when you include macros and call/cc). I wrote a minimal stack-based language years ago and I still cannot get a handle around Forth. The inner interpreter and immediate words? Even after reading Let over Lambda, Forth is greek to me.
But, to be fair, getting to the point of being able to implement a recursive fibonacci algorithm is not too difficult taking either path.
- codr77 8y agoI mean simple as in primitive and easy to implement. Using Forth effectively takes practice, but I found it worth the effort for the much the same reasons as Lisp.
- kazinator 8y agoForth is really a kind of assembly language for a virtual machine, and not really a higher level language. It looks higher level because it doesn't have registers. Register machine languages are "catenative" also. We can take a "mov eax, ebx" and catenate that with "move ecx, $foo" in any order we want. We are constrained, though, because different sections of code use different input and output registers (or combinations of input and output registers and stack locations and such). Forth makes those conventions uniform, and that leads to some degrees of freedom which give it a higher level flavor. The thing to do is to make some higher level language that uses Forth as a VM; then you have understandable code.