Files
AutomateTheBoringStuffWithP…/practice_projects/StripByRegex.py

15 lines
419 B
Python
Raw Normal View History

2017-06-14 17:18:59 +08:00
#! python3
'''
Regex Version of strip()
Write a function that takes a string and does the same thing as the strip()
string method. If no other arguments are passed other than the string to strip,
then whitespace characters will be removed from the beginning and end of
the string. Otherwise, the characters specified in the second argument to
the function will be removed from the string.
'''
def stripInRegexWay()