You are viewing a single comment's thread. Return to all comments →
I think I could have solved this particular problem without really needing to know how many numbers are going to be in the second line.
Let's say we only have numbers as the input:
numbers = raw_input().strip().split()
for i in range(len(numbers)):
numbers[i] = int(numbers[i])
T = tuple(numbers)
Am I missing something?
Edit: I just learned that I can use map to convert all the strings in a list to integers! No need of that for loop too!