This seems like it should be trivial, but how do I partition a string into length n substrings? I can of course write something like
chunk[s_, n_] := StringJoin[#] & /@ Partition[Characters[s], n]so that chunk["ABCDEF",2] ->{"AB","CD","EF"} but this appears unnecessarily cumbersome.