finallist = []
for each_time in range(10):
x = int(input("Whats your number ? "))
finallist.append(x)
It ask 10 times "Whats your number ? "
and .append
the obtained answer with input()
as int
into a list, i wanted to know it there are any simple way of doing this, with map maybe ? i've read on similar problems somethings about json
too.
finallist.append(int(input("Whats your number ? ")))
I know i can do this, but for reasons of explanation, i preferred to write the first one.