0

Cannot produce prompt question on Chromebook?

I am learning Python and in the "Taking user input" lesson I typed code to add a question to the user input prompt. However, all I keep on getting is the message "Seems like your program requires an input". The question does never pop-up. What can be the cause? I am working from a Chromebook, on the SoloLearn website. This is the code: name = input("Enter your name: ") print("Hello, " + name)

24th Mar 2021, 8:15 PM
Judith
Judith - avatar
8 ответов
0
Type anything and the code will display the result. If it isn't, is it a bug?
24th Mar 2021, 8:24 PM
Dino Wun (Use the search bar plz!)
Dino Wun (Use the search bar plz!) - avatar
0
that's the way code playground works at sololearn: all input are taken at once before running script (but after clicking 'run'), because codes are executed on server side... so all inputs are collected, then send with script to server, where output is collected and finally returned to be displayed ^^
24th Mar 2021, 8:42 PM
visph
visph - avatar
0
Thanks guys for responding, Not sure I understand here. I need to be more clear probably. I am dloing the Python course on a chromebook. Online. So the website then says: "try yourself". So I am using the online IDE on sololearn (if thats the correct word for it). I haven't installed any IDE yet (and prefer not to unless it is easy and doesn't slow down the chromebook since it's my boyfriend's) See here for the screenshots: https://snipboard.io/lBTP9o.jpg https://snipboard.io/JbS8s7.jpg Thanks!
24th Mar 2021, 8:48 PM
Judith
Judith - avatar
0
yes: you run script in sololearn code playground, so that's it ;)
24th Mar 2021, 8:49 PM
visph
visph - avatar
0
Thanks Visph. I am a total n00b so I assume you mean that something happens on the way to the server that is causing my question prompt to not appear on my screen? I have no idea what this means for other coding. Would the same happen on a Windows computer without a Python installation? Or is it purely a chromebook related problem? I am trying to understand everything.
24th Mar 2021, 9:07 PM
Judith
Judith - avatar
0
yes, the device where you run sololearn code playground (app or website) will produce the same popup... in fact, the script is basically parsed to search for 'input' inside it, and popup occurs even if 'input' is found in comments ;P only web languages (html/css/js and php) are run on client side... meaning with real user interactivity ^^
24th Mar 2021, 9:11 PM
visph
visph - avatar
0
So trying the code on replit wouldn't solve my issue then?
24th Mar 2021, 10:09 PM
Judith
Judith - avatar
0
I don't know: I'm talking about sololearn code playground... if replit handle scripts as sololearn, you must have some way to get inputs just before running them (but after clicking the 'run' -- or equivalent -- button), else it will allow for 'real' script interaction... that's not because scripts running on server side doesn't allow 'real' interactivity, that's because sololearn handle them this way ^^ as an example, I can run interactively scripts on pythonanywhere.com without this sololearn limitation...
25th Mar 2021, 3:00 AM
visph
visph - avatar