+ 2
How to get multiple inputs in python and javascript?
2 odpowiedzi
+ 2
Python:
a = input()
b = input()
Or:
inps = input().split(“ “)
# str to list
a, b = tuple(inps)
# to tuple then unpacks it
... for two terms separated by space, like “1 2”.
Note that in SoloLearn you only input once, but that’s just for SL. For too much input info, it’s better to read it from a txt file.
0
thnx