#!/usr/local/bin/python2 from collections import deque for i in xrange(100000): l = range(200) d = deque(l) l.pop(0)