Answers for "trim starting space python"

2

python trim whitespace from end of string

>>> "    xyz     ".rstrip()
'    xyz'
Posted by: Guest on May-07-2020
0

trim starting space python

>>> s = "  abc"
>>> s = s.lstrip()
>>> s
'abc'
Posted by: Guest on July-18-2021

Python Answers by Framework

Browse Popular Code Answers by Language