Returns a copy of the string with the leading and trailing characters removed.
str. strip([chars])
- chars
- Optional. String specifying the set of characters to be removed. If omitted or None, the chars argument defaults to removing whitespace. The chars argument is not a prefix; rather, all combinations of its values are stripped.
str
#TODO
>>> ' spacious '.strip()
'spacious'
>>> "AABAA".strip("A")
'B'
>>> "ABBA".strip("AB")
''
>>> "ABCABBA".strip("AB")
'C'>>> 'www.example.com'.strip('cmowz.') # this example extracts web address
'example'