Substring: Difference between revisions

Content added Content deleted
(Add lang example)
Line 2,734: Line 2,734:


<syntaxhighlight lang="j"> 'Marshmallow'{~(+i.)/3 5
<syntaxhighlight lang="j"> 'Marshmallow'{~(+i.)/3 5
shmal</syntaxhighlight>

Or, probably more efficient when the string is large:

<syntaxhighlight lang="j"> (,.3 5)];.0 'Marshmallow'
shmal</syntaxhighlight>
shmal</syntaxhighlight>