Get Last N Characters of String using Python July 9, 2021 Python 0 Comments 269 Views Slicing text = 'HelloWorld!' n = 6 result = text[-n:] print(result) # World!
Leave a Comment
Cancel reply