Talk:INPUT

From C64-Wiki
Jump to navigationJump to search

Suppressing "?"[edit source]

"Using POKE 19,1 will" - is this true for all platforms, or just certain models? Maury Markowitz (talk) 21:08, 25 November 2020 (CET)

This should be works on every real C64 --Jodigi (talk) 21:32, 27 November 2020 (CET)


This differs on platforms, above works at least for C64, VC-20, C16/C116/C264, but on a C128 this is at location $15/21, see C128 zeropage (there is currently only a german version). --JohannKlasek (talk) 21:34, 3 December 2020 (CET)

BASIC V1 behavior[edit source]

Empty Input[edit source]

BASIC V1 of the PET series differs in that an empty input, pressing the return key with no other characters, will stop execution of the current program and exit to the READY prompt.

Details:

I'm asking about this note in the wiki:

   If the user presses RETURN  without providing any data, the contents of the variables remains unchanged.

Consider this program in the Online PET emulator:

   10 INPUT A
   20 GOTO 10

If I type a value in when prompted, it goes back to 10:

? 1
? 25
? 33

But if I simply hit return, it exits the program:

? 

READY.

So I think there is perhaps some additional subtlety here? Maury Markowitz (talk) 22:29, 11 October 2024 (CEST)

Normally not on a C64 or C64 emulator.
It looks that in BASIC V2 or higher for the Plus/4 and C128 the programm wait until INPUT gets a value.
If you enter an empty value, you will get the INPUT-?-prompt again on a C64/128.
Remark: This article describes the BASIC command INPUT in BASIC V2 at the Commodore 64.
--Jodigi (talk) 23:35, 11 October 2024 (CEST)
The notice regarding BASIC V1 has been removed. This is not the right place to describe BASIC V1 behavior. The discussion tab is an intermediate possibility to hold this information. It would be better to create a separate page for INPUT (BASIC V1), maybe with reference or similar content of BASIC V2's INPUT and some deviating information. --JohannKlasek (talk) 19:42, 3 November 2024 (CET)
Template:ping Why do you believe this is the wrong page to describe this? The difference on the PET is literally described in a single sentence, why would we want an entire separate page that differs only in a single statement? This page is the landing point for all >2.0 versions of BASIC, including other non-C64 machines, so if it is appropriate for >2.0, why not <2.0? I am a bit baffled by this logic. Maury Markowitz (talk) 14:40, 13 January 2025 (CET)
Did you read the remark from Jodig above? What does it say? "Remark: This article describes the BASIC command INPUT in BASIC V2 at the Commodore 64." This describes the V2 version only and on a C64 (not a PET or any other CBM relative) - by definition. This information has absolutely no meaning to people this page is primarily targeted: programming BASIC V2 on a C64. There are other separate page collections for BASIC 3.5, BASIC 7.0 and various other extensions. We want the keep the structure and prevent mixing pages up by collecting off-topic information on a page. Does this make sense to you?
However, I would suggest to put your knowledge bit into the Trivia section to provide a historical view how the V2 version evolved. --JohannKlasek (talk) 22:50, 16 January 2025 (CET)