Function [s,ndelim nlast] = strprefix(s,pre1,pre2)
[s,ndelim,nlast] = strprefix(s,pre1,pre2,delim)
returns the string after prefixing string pre1 to the
input string s and after prefixing string pre2 to the
second, third etc. of its lines.
At default, the function looks for newlines "\n" in
string s. Instead of this, an other delimiter delim may be
given.
Optionally, the number of lines (or parts delimited by
delim) is returned in the second output argument.
Optionally, the length of the last line (or last part
delimited by delim) is returned in the third output
argument.
(c) 2026 fabien van mook
2026.08.20 release of this file within package "fvm-valuetocode" under GNU GPLv3+