You are viewing a single comment's thread. Return to all comments →
Here is how I broke this down:
n = raw_input()
input_line = raw_input()
input_list = input_line.split()
for i in xrange(n): input_list[i] = int(input_list[i])
for i in xrange(len(input_list)): input_list[i] = int(input_list[i])
input_list = map(int, input_list)
input_list = [int(x) for x in input_list]
Now input_list looks like this: [1, 2, 3, 4]
input_list
t = tuple(input_list)
print hash(t)
raw_input().strip()
Seems like cookies are disabled on this browser, please enable them to open this website
Tuples
You are viewing a single comment's thread. Return to all comments →
Here is how I broke this down:
Now
input_list
looks like this: [1, 2, 3, 4]Other Optimizations (Not necessary for credit here):