The strings one after another, with separator between them.
assert(join("a", "b", "c", separator = "-") == "a-b-c");join :: (
inputs: ..string,
separator := "",
before_first := false,
after_last := false
) -> string
The strings one after another with separator between them, in a new string that the caller frees.
Parameters
- inputs: ..string
- separator := ""
- goes between the strings.
- before_first := false
- also put the separator before the first string.
- after_last := false
- also put the separator after the last string.
Returns
- string
joined := join("a", "b", "c", separator = ", ");
defer free(joined);
assert(joined == "a, b, c");