4 Risposte
+ 8
Sololearn runs your Python program as a background batch job. In order give it input, the batch job must read input from a file. By design, batch jobs cannot be interactive with a console. So, before running your program, the script that submits the batch job scans your source code for input keywords. If it finds any, then it prompts you for the input and stores your entries into the file that is later provided to the batch job at run time. Because the input is gathered before runtime, it does not know what the prompt should be. It just asks generically for you to enter whatever the program may expect as input.
+ 4
I always add comments in my Python code so the user will know what the input is for. I also add a default input so the program doesn't crash if the user doesn't enter any input.
+ 3
Petr Nedoma You are clearly spamming the forums and I sent you a DM as a courtesy. Please review the forum guidelines.
https://www.sololearn.com/Discuss/3021159/?ref=app
+ 2
maybe you think for something like this?
input("please enter a/n...:" )