So I know that I can use either the "%" or ".format" syntax to format string, particularly to trim the end of string to a set number of characters:
>>> print("%s" % "12345678990")
12345678990
>>> print("%.5s" % "12345678990")
12345
Is there any way to trim the beginning of the string using string formatting (not slicing, etc)? The desired output would be:
>>> print("%<lst3>" % "12345678990")
990
I have tried the following, to no avail:
"%.-3s"
"%.=3s"
"%.:3s"
"%.:-3s"
And so on.
I have seen nothing in the docs about this, but would be happy to be proven wrong! Any help is appreciated.