Poll: Include Key Codes in Program Listings
This poll is closed.
Yes 78.95% 15 78.95%
No 0% 0 0%
Indifferent 21.05% 4 21.05%
Total 19 votes 100%
* You voted for this item. [Show Results]

Post Reply 
Key Codes in Program Listings (70's/80's calculators)
04-15-2024, 01:20 AM (This post was last modified: 04-15-2024 01:34 AM by carey.)
Post: #2
RE: Key Codes in Program Listings (70's/80's calculators)
(04-15-2024 12:38 AM)Eddie W. Shore Wrote:  I don't remember if I asked this before but for calculators from the 70s/80s (25C, 65, 67, 12C, 11C, 15C, etc), but what style of listing would you prefer?

Style 1 where the key codes are included:
Example: (15C)
001 ; 42, 21, 11 ; LBL A
002 ; 1 ; 1
003 ; 40 ; +
004 ; 43, 32 ; RTN


Style 2 where it's just step numbers and keys:
001 LBL A
002 1
003 +
004 RTN


I've been listing my programs in style 1 and considering dropping the key codes.

I find Style 1 preferable for the 15C (the only one of the listed calculators I use) because including key codes offer the advantage of providing a check (similar to a checksum and useful for long listings) that the correct keys were pressed.

Since Style 2 has the advantage of making program logic clearer, if Style 1 could be modified so keys are indented and aligned to the right (as below), both Style 1 and Style 2 advantages could be achieved (though with more work for the author! :)

Code:
Modified Style 1:
Example:   (15C)
001 ;  42, 21, 11 ; LBL A
002 ;  1 ;          1
003 ;  40 ;         +
004 ;  43, 32 ;     RTN

Another possibility is Style 2 for short programs and Style 1 for long programs.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Key Codes in Program Listings (70's/80's calculators) - carey - 04-15-2024 01:20 AM



User(s) browsing this thread: 1 Guest(s)