c0de 0.3.0This page in English

Diese Seite ist noch nicht übersetzt. Sie wird auf Englisch angezeigt.

REPLACE ​

Overwrites characters of a text with another text.

The length of the text stays the same. Characters of insert that would make it longer are dropped. A start behind the end of the text raises INVALID_ARGUMENT.

Parameters and results

  • text STRING: the text
  • start INTEGER: the position where overwriting begins
  • insert STRING: the new characters
  • result result STRING: the changed text

Example

c0de
CALL c0de/strings/REPLACE
    PARAMETER text "Hello Alex" ;
    PARAMETER start 6 ;
    PARAMETER insert "Stev" ;
    RESULT result greeting