Ver originaldef chunks(l, n): """Yield successive n-sized chunks from l.""" for i in xrange(0, len(l), n): yield l[i:i+n] txt = "Este es un texto para dividir"for block in chunks(txt, 5): print block