Tail
Arguments
Explanation
Examples
"Hello!".tail(1) == "!"
// Goat emoji is a surrogate of two bytes
"ππ".tail(2) == "π"Last updated
Was this helpful?
type
returns
method
string
name
type
description
size
int
the amount of characters to grab
Returns a substring of the given size, starting at the string's last character. Roughly equivilent to #slice(-size)
"Hello!".tail(1) == "!"
// Goat emoji is a surrogate of two bytes
"ππ".tail(2) == "π"Last updated
Was this helpful?
Was this helpful?