[Coco] REPEAT UNTIL Problems in Basic09 ?

James Jones jejones3141 at gmail.com
Fri Jul 10 23:33:24 EDT 2020


Wow... I never saw an error #27 before, and I couldn't have told you what
it meant! Thank you.

I would say that unless you were intending to experiment with REPEAT UNTIL,
you might consider

PROCEDURE t
    DIM i, n:INTEGER
    FOR i:=ASC("A") TO ASC("Z")
        FOR n:=1 TO 10
            PRINT CHR$(i);n
        NEXT n
    NEXT i



On Sun, Jul 5, 2020 at 12:15 PM <coco at jechar.ca> wrote:

> SORRY IT WAS ME look at the codeline I added between the { }
> the Basic09 compiler was actually being quite smart and detecting
> an Infinite Loop
>
> On 2020-07-05 13:05, coco at jechar.ca wrote:
> > System: Emulator 6309 Basic09
> >
> > Problem: This Code Fails the error says
> >
> > ENDNTIL
> > ERROR #27
> > which is a MISSING ASSIGNMENT STATEMENT
> >
> > THIS IS THE CODE
> >
> > PROCEDURE t
> >
> > DIM alpha$:STRING
> > DIM numeric,i:INTEGER
> > DIM DONE:BOOLEAN
> >
> > DONE=FALSE
> > i=65
> > REPEAT
> >   numeric=1
> >   REPEAT
> >     alpha$=CHR$(i)
> >     PRINT alpha$;numeric
> >     numeric=numeric+1
> >   UNTIL (numeric>10)
>     { i=i+1 } Adding this code here fixes the problem.
> >   IF alpha$="Z" THEN
> >      DONE=TRUE
> >   ENDIF
> > UNTIL DONE
> >
> > END
> >
> >
> > IS IT ME OR IS THERE SOMETHING
> > WRONG WITH THE COMPILER?
> >
> > Charlie
> Sorry
>
> --
> Coco mailing list
> Coco at maltedmedia.com
> https://pairlist5.pair.net/mailman/listinfo/coco
>


More information about the Coco mailing list