Wolfram Language & System 10.4 (2016)|Legacy Documentation
This is documentation for an earlier version of the Wolfram Language.View current documentation (Version 11.2)
partitions string into nonoverlapping substrings of length n.
generates substrings with offset d.
- All the substrings generated by StringPartition[string,n,d] are of length n. Some elements at the end of string may therefore not appear in any substring.
- StringPartition[string,UpTo[n]] partitions into substrings of length up to n, allowing the final substring to be shorter.
- All elements of string appear in the substrings generated by StringPartition[string,n,1].
- If d is greater than n in StringPartition[string,n,d], then elements in the middle of string are skipped.
Introduced in 2015
(10.1)| Updated in 2016