how to remove string whitespace python code example
Example 1: python delete white spaces
sentence = ' hello apple'
sentence.strip()
>>> 'hello apple'
Example 2: python string remove whitespace
' sss d ssd s'.replace(" ", "")
# output: 'sssdssds'