0
I try to open a python file, but it immediately closes after its opened, Anybody know how to fix this?
Just wanna know.
5 Réponses
+ 6
Can you save that code here in SoloLearn and share the code link for analysis?
Idk for sure, but does it help if you add an input() call at the end of the code, just so the code waits for input before exiting?
+ 1
If you're on Windows change extension to .pyw, it should make the window persist
+ 1
Ipang's or Steven's fix should work.
But on windows i use batch files with "@pause" as the last line. This also pauses the window so you can see the output without changing the code directly
https://datatofish.com/batch-JUMP_LINK__&&__python__&&__JUMP_LINK-script/
0
Now it doesn't show up at all.
0
Open Command Prompt and run the file through Command Prompt