Say I have a Python list like this:
letters = [\'a\',\'b\',\'c\',\'d\',\'e\',\'f\',\'g\',\'h\',\'i\',\'j\']
I want to insert an \'x\' after
l = ['a','b','c','d','e','f','g','h','i','j'] [ l.insert(n+(n+1)*i, 'x') for i in range(len(l)/n) ] print l