s = raw_input("How many sides?: ") p = 0 for side in range(int(s)): side = raw_input("What is the length of the side?: ") p += float(side) print "The perimeter is %d" %(p)