Not sure if the docs are confusing, but the second parameter is the position, which is counted from end backwards when negative value. The length, the third parameter, is always counted forward (never backwards). So if you want to get the last 10 chars:

$var(num)=$(fU{s.substr,-10,10})

Feel free to improve the docs.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.