Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.sys.apple2.programmer > #6295
| Newsgroups | comp.sys.apple2.programmer |
|---|---|
| Date | 2023-12-30 11:15 -0800 |
| References | <20231226114951.65d00993@smilodon-gracilis> |
| Message-ID | <6563cfc4-a4d3-43ab-b468-ee9d98dc3f4fn@googlegroups.com> (permalink) |
| Subject | Re: Compiler Brain Dump - Your Chance to Tell Me How Wrong I am - Haha |
| From | I am Rob <gids.rs@sasktel.net> |
> I found ZBASIC. I've been looking at different structured BASICs and > compilers. ZBASIC seems pretty awesome. It can even do DHGR. Does > anyone have any experience or comments about it? It builds BIN > programs. > > I've eliminated other BASIC compilers because they don't have > "structured" statements like WHILE/WEND, REPEAT/UNTIL, > IF/ELSE/ENDIF, optional line numbers & Functions with parameters. > If you don't have those, you're still just writing a bunch of GOTOs that > are very hard to read. I love ApppleSoft BASIC, but for large programs, > it gets pretty hard to manage. > I can write Assembly "Language" but it is so slow to write simple > things. And most people can't even read it. > I want other people to be able to read and understand my code. I feel > like it is a means of communicating how to accomplish tasks and how the > machine works. There are add-ons for Applesoft Basic. There is an IF/ELSE/THEN and REPEAT/UNTIL add-on. The REPEAT/UNTIL is actually quite a bit faster than a FOR/NEXT loop. For the most part, most people just don't know how to program Applesoft Basic efficiently. If you are using too many GOTO's in your programs, then should consider using more ON/GOTO's or better yet ON/GOSUB. instead of: 10 GET CHOICE 15 IF CHOICE=1 THEN GOT0 xxyy 20 IF CHOICE=2 THEN GOTO yyxx you would use 10 GET CHOICE 15 ON CHOICE GOSUB 100,200,300 20 GOTO 10 100 DOTHIS : RETURN 200 DOTHAT : RETURN 300 DOMORE : RETURN There is even an add-on that reduces line #15 to 15 GOSUB 100*CHOICE Another add-on allows for GOTO/GOSUB "label" to identify your subroutines. As for Machine Language, once you start collecting or creating sub-routines, it becomes very efficient down the road as the subroutines can then be imported into larger programs. You will see a lot of source code that has INCLUDE "subroutine". But higher languages are difficult to program to use imported sub-routines.
Back to comp.sys.apple2.programmer | Previous | Next — Previous in thread | Next in thread | Find similar
Compiler Brain Dump - Your Chance to Tell Me How Wrong I am - Haha Bill Chatfield <bill_chatfield@yahoo.com> - 2023-12-26 11:49 -0500
Re: Compiler Brain Dump - Your Chance to Tell Me How Wrong I am - Haha Brian Patrie <bpatrie@bellsouth.spamisicky.net> - 2023-12-27 05:35 -0600
Re: Compiler Brain Dump - Your Chance to Tell Me How Wrong I am - Haha Bill Chatfield <bill_chatfield@yahoo.com> - 2023-12-27 11:24 -0500
Re: Compiler Brain Dump - Your Chance to Tell Me How Wrong I am - Haha I am Rob <gids.rs@sasktel.net> - 2023-12-30 11:15 -0800
Re: Compiler Brain Dump - Your Chance to Tell Me How Wrong I am - Haha Bill Chatfield <bill_chatfield@yahoo.com> - 2023-12-31 11:37 -0500
Re: Compiler Brain Dump - Your Chance to Tell Me How Wrong I am - Haha I am Rob <gids.rs@sasktel.net> - 2023-12-31 13:17 -0800
Re: Compiler Brain Dump - Your Chance to Tell Me How Wrong I am - Haha fadden <fadden@fadden.com> - 2024-01-01 07:42 -0800
Re: Compiler Brain Dump - Your Chance to Tell Me How Wrong I am - Haha I am Rob <gids.rs@sasktel.net> - 2024-01-01 13:07 -0800
csiph-web