Function replace()
replaces substring1 of a string with substring2 and return the new string.
Arguments:
- String <string | text>
- Substring1 <string>
- Substring2 <string>
Returns:
- String <string>
Comman Usage
Exalmple: Direct calculate
uncollect ["cut", "tub"] as a
uncollect [["u", "a"],["t", "p"]] as b
return replace(a, b[0], b[1])
| replace(a, b[0], b[1]) |
|------------------------|
| cat |
| pub |
Exalmple: Multiply and calculate
uncollect ["cut", "tub"] as a
uncollect [["u", "a"],["t", "p"]] as b
with replace(a, b[0], b[1]) as c
return c
| c |
|-----|
| cat |
| cup |
| tab |
| pub |