Changes

Jump to navigation Jump to search
33 bytes removed ,  13:17, 2 August 2016
<li>Line numbering:
<pre class="brush:xquery">
let $number-lines words := function($str) {
fn:string-join(
fn:for-each-pair(
1 to 1000,
tokenize($str, '\r?\n|\r+'),
concat(?, ': ', ?)
),
'&amp;#xa;'
)
}
return $number-lineswords('hello world, how are you?')
</pre>
''Result:''
<pre class="brush:xquery">
1: hello world,how2: how are 3: you?
</pre>
</li>
Bureaucrats, editor, reviewer, Administrators
13,550

edits

Navigation menu