Builtins.setIndex3kaya
Change a character in a string in-place
Usage
Void setIndex( String s, Char c, Int i )
Arguments
s The string
c The character to set (may not be a NULL)
i The position in the string
Overview
Sets the i th character of the given String to the given character. The index starts at zero.
-
str = "abcdefg";
setIndex(str,'-',4); // str = "abcd-fg"
An Builtins.IllegalIndex (3kaya) exception is thrown if i is out of bounds.
Releases
4 releases since Debian 5.0 (Lenny); the text changed 3 times.