semvec/pypi-packages huggingface dataset:
left-pad 0.0.3
Pad a string to the left with any number of characters
License: BSD

Pad a string to the left with any number of characters

    pip install left-pad

Then

    >>> from left_pad import left_pad
    >>> s = "abc"
    >>> left_pad(s, 2, "+")
    '++abc'

Make sure to add left-pad to your dependencies in your next project.

Or, if you want to reinvent the wheel, go ahead and try to do it
with the standard library

    >>> s.rjust(len(s) + 2, '+')
    '++abc'