Skip to main content

$$substring

Gets a slice of an array by indices (negative begin index will slice from the end)

Usage​

"$$slice(<begin>,[end]):{input}"

Returns​

array (same items type as input)

Arguments​

ArgumentTypeValuesRequired / Default ValueDescription
beginintegerYesIndex of first character to slice from (if negative, counts from the end of the string)
endintegerIndex of last character to slice to (if negative, counts from the end of the string)

Examples​

Input

Definition

Output

"hello"
"$$substring(1,3):$"
"ell"
"hello-world"
"$$substring(-5):$"
"world"