Join Slack
Communities
Powered by
is there a built-in way to retrieve both the strin...
# getting-started
u
uhe
02/15/2017, 12:28 PM
is there a built-in way to retrieve both the string before and after the last occurrence of a specific character? e.g.
val (before, after) = "1:2:3".partitionAfterLast(':') // before == "1:2", after = "3"
Open in Slack
Previous
Next