DelimitedSequence
DelimitedSequence[form]
represents a delimited sequence of elements of the specified form in Interpreter and related functions.
DelimitedSequence[form,sep]
assumes a separator that matches sep.
DelimitedSequence[form,{left,sep,right}]
assumes left and right delimiters matching left and right, respectively.
Details
- DelimitedSequence[form] allows any sequence of objects of type form separated by white space or punctuation in a way that cannot occur inside the objects.
- The separator sep and delimiters left and right can be literals or string patterns.
- Restricted can be used to put restrictions on the length of the sequence.
Examples
open allclose allBasic Examples (5)
Applications (1)
Use DelimitedSequence in a form to accept a simple list of elements:
Possible Issues (2)
DelimitedSequence of all types that use the connection to the Wolfram Cloud will only use a semicolon as an automatic delimiter, to avoid confusion with natural-language names of elements:
You can still explicitly specify delimiters:
When DelimitedSequence fails to parse an element in the sequence the whole result is a Failure object:
Text
Wolfram Research (2014), DelimitedSequence, Wolfram Language function, https://reference.wolfram.com/language/ref/DelimitedSequence.html (updated 2016).
CMS
Wolfram Language. 2014. "DelimitedSequence." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2016. https://reference.wolfram.com/language/ref/DelimitedSequence.html.
APA
Wolfram Language. (2014). DelimitedSequence. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/DelimitedSequence.html