How do I remove white space in Python?

Đinh Yến

New member
How do I remove white space in Python?
Answer
Python String strip() function will remove leading and trailing whitespaces. If you want to remove only leading or trailing spaces, use lstrip() or rstrip() function instead.
 

Tìm kiếm

Back
Top