code: def grouper(n, iterable, fillvalue=None):
      "grouper(3, 'ABCDEFG', 'x') --> ABC DEF Gxx"
      args = [iter(iterable)] * n
      return itertools.izip_longest(fillvalue=fillvalue, *argsf grouper(n, iterable, fillvalue=None):
      "grouper(3, 'ABCDEFG', 'x') --> ABC DEF Gxx"
      args = [iter(iterable)] * n
      return itertools.izip_longest(fillvalue=fillvalue, *args)
docs: grouper(3, 'ABCDEFG', 'x') --> ABC DEF Gxx