Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

INPUT into arrays #55

Open
richpl opened this issue Oct 18, 2021 · 2 comments
Open

INPUT into arrays #55

richpl opened this issue Oct 18, 2021 · 2 comments

Comments

@richpl
Copy link
Owner

richpl commented Oct 18, 2021

Placeholder to add support for user input directly into an array variable

@cclauss
Copy link
Contributor

cclauss commented Oct 29, 2021

Would it be possible to provide an example of the BASIC syntax that should be supported?

@RetiredWizard
Copy link
Contributor

RetiredWizard commented Oct 29, 2021

     10 DIM A(10)
     20 FOR I = 1 TO 10
     30 PRINT "ENTER VALUE NUMBER ";I;
     35 REM *** THE FOLLOWING STATEMENT DOESN'T CURRENT WORK PROPERLY ***
     40 INPUT ": ";A(I)
     50 NEXT I
     60 PRINT "YOU ENTERED: ";
     70 FOR I = 1 TO 10
     80 PRINT A(I);", ";
     90 NEXT I
     100 PRINT
     >RUN
     ENTER VALUE NUMBER 1: 1
     ENTER VALUE NUMBER 2: 7
     ENTER VALUE NUMBER 3: 0
     ENTER VALUE NUMBER 4: 1
     ENTER VALUE NUMBER 5: 6
     ENTER VALUE NUMBER 6: 9
     ENTER VALUE NUMBER 7: 6
     ENTER VALUE NUMBER 8: 4
     ENTER VALUE NUMBER 9: 0
     ENTER VALUE NUMBER 10: 3
     YOU ENTERED: 0, 0, 0, 0, 0, 0, 0, 0, 0, 0

     *** SHOULD BE ***
     YOU ENTERED: 1, 7, 0, 1, 6, 9, 6, 4, 0, 3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants