My Python Quiz

The ultimate place to learn Python!

Question #45: What gets printed?

confusion = {}
confusion[1] = 1
confusion['1'] = 2
confusion[1.0] = 4

sum = 0
for k in confusion:
    sum += confusion[k]

print sum