How to remove spaces from a string in Python?
Answer / nashiinformaticssolutions
Python's strip() and replace() functions can be used to eliminate spaces from a string. The replace() function eliminates all of the white spaces in the string, while the strip() function eliminates the leading and following white spaces.
Is This Answer Correct ? | 0 Yes | 0 No |
What is self in python constructor?
How do you create a database in python?
Is python a procedural language?
What is *args and **kwargs?
What is a metaclass in Python?
Explain the difference between append vs extend in list?
How do you write a function in python 3?
What is the difference between ‘match’ and ‘search’ in python?
Why python is so popular?
What are the rules for a local and global variable in python?
Is there a way to remove the last object from a list?
Is python slower than c?