I am receiving a series of numbers from an API. Here is how they look:
1,2,3,4,5,6
My goal is to only display the last digit instead of all of them.
How can I achieve this? I know that I need to add .slice
at the end, but I'm unsure about what to put inside the parentheses.
Thank you, Sam