I have a string as below:
str = "abcdefg123"
I want to get the last character(3), how to make it by coffeescript?
I am a newcomer to coffeescript, hope someone can help me, thanks in advance!
Enjoy some Coffeescript destructuring assignement and splats:
str = "abcdefg123"
[..., lastChar] = str
alert lastChar
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With