+ 1

New version of "to_str3a just posted

https://code.sololearn.com/c74KHn9ruTXK/?ref=app I just posted a new version of to_str3a.py, a number to string converter, on SoloLearn. This version has exception handling. This works fine on my machine but on sololearn you must use the input function instead of sys.stdin.readline(). On sololearn you must pre-enter your input data and then run the program. If you forget the extra \n to terminate the program, it will loop for ever looking for a valid input, which will never come. Is there a way I can get the program to work both on interactive input and on pre-entered input correctly?

4th Aug 2018, 5:34 AM
Rick Shiffman
Rick Shiffman - avatar
1 Antwort
+ 2
It is better to post your nonweb codes in a thread like this: https://www.sololearn.com/Discuss/347139/?ref=app More people will see it!
4th Aug 2018, 5:57 PM
Paul
Paul - avatar