[Coco] Let's say you wrote a BASIC program the user is invited to change

Rob Rosenbrock bester at adamswells.com
Thu Jul 10 15:51:49 EDT 2025


My thoughts, too. Is this something that could be stored in a config file and read in at time of execution?

Sent from my iPhone

> On Jul 10, 2025, at 2:10 PM, Bruce W. Calkins via Coco <coco at maltedmedia.com> wrote:
> 
> 
> 
>> On 7/10/25 12:08, Juan Castro via Coco wrote:
>> For example, it solves an equation, or plots a graph, and the user is
>> supposed to edit the line where the function is defined. So you print
>> a message telling them they can edit line XXX for that purpose.
>> Or you want to say the user can change something's color by changing
>> the value of variable C in line YYY.
>> If you renumber the program, you'll have to go back and re-edit any
>> message like that, right? Well, no longer. Now you can use "GOTO nnnn"
>> as an expression and print it! Like this:
>> https://www.dropbox.com/scl/fi/gy5svbpsycvmr1uc8c70c/GOTOasExpression.mp4?rlkey=fit9ljec12on0ri4oxq0yp0wo&st=71tbzuls&dl=0
>> The only change was in the expression evaluation routine. If I find
>> the tokens for GOTO, I skip them and otherwise act normally. RENUM
>> didn't need any changes -- whenever it finds a GOTO followed by a
>> number, it changes it.
>> As usual, you can find the stuff here:
>> https://www.dropbox.com/scl/fo/9p5ydq5hqgp4b1fbqyyif/AKnngotPgk1PLUm6kw0nn5U?rlkey=pxtfum7dzwno0ej42bfb8ucrb&st=duyykgkj&dl=0
>> Juan Castro
>> Enviado do meu Olivetti Programma 101
>> http://retropolis.com.br
> 
> Why not have the user input the variables, or accept the defaults?
> 
> Seems to me encouraging the user to change the program is inviting disaster.
> 
> Bruce W.
> 
> -- 
> Coco mailing list
> Coco at maltedmedia.com
> https://pairlist5.pair.net/mailman/listinfo/coco



More information about the Coco mailing list