[Coco] [Color Computer] pagetable.com > Blog Archive > Bill Gates' Personal Easter Eggs in 8 Bit

Arthur Flexser flexser at fiu.edu
Thu Oct 2 22:45:37 EDT 2008


PRINT and '?' both get tokenized to the single-byte token for the print command
(which is different from the Ascii code for '?'.)  I'd guess PRINT got special
treatment because of its frequent use in direct mode to print out the values of
variables to aid in debugging.

I'm pretty sure I recollect the question mark being used as a substitute for
PRINT in various BASICs prior to the introduction of the CoCo.  I'm less certain
about the apostrophe substitute for REM predating the CoCo, though I suspect it
does.

Art

On Thu, 2 Oct 2008, John wrote:

> Hello Art,
> 
> Is this tokenization to one byte the functionality that provides "shortcuts"
> like typing "?" for "PRINT" ?  I've always wondered why that one command had
> such a shortcut.
> 
> Just curious,
> John
> 
> -----Original Message-----
> From: coco-bounces at maltedmedia.com [mailto:coco-bounces at maltedmedia.com] On
> Behalf Of Arthur Flexser
> Sent: Thursday, October 02, 2008 12:06 AM
> To: CoCoList for Color Computer Enthusiasts
> Subject: Re: [Coco] [Color Computer] pagetable.com > Blog Archive > Bill
> Gates' Personal Easter Eggs in 8 Bit
> 
> All CoCo commands are tokenized to a single byte.  (Functions, to
> distinguish
> them from commands, use two bytes.)  This excludes commands like SAVEM, in
> which
> the "M" essentially acts as an argument to the SAVE command, which is
> efficient
> for saving ROM space and adds negligibly to execution time.
> 
> Art
> 
> On Wed, 1 Oct 2008, James Diffendaffer wrote:
> > 
> > The Dragon's interpreter is faster than the CoCo's. 
> > That alone should tell you the CoCo's Basic wasn't optimized well.
> > They didn't even bother to worry about what tokens were one or two
> > bytes.  The most commonly used commands should have used single byte
> > tokens but not all do.
> > 
> 
> 
> --
> Coco mailing list
> Coco at maltedmedia.com
> http://five.pairlist.net/mailman/listinfo/coco
> 
> 
> --
> Coco mailing list
> Coco at maltedmedia.com
> http://five.pairlist.net/mailman/listinfo/coco
> 




More information about the Coco mailing list