RosettaCodeData/Task/Substring/Frink/substring.frink
2023-07-01 13:44:08 -04:00

12 lines
262 B
Text

test = "🐱abcdefg😾"
n = 3
m = 2
println[substrLen[test, n, m]]
println[right[test, -m]]
println[left[test, -1]]
pos = indexOf["c"]
if pos != -1
println[substrLen[test, pos, m]]
pos = indexOf[test, "cd"]
if pos != -1
println[substrLen[test, pos, m]]