To Remove Whitspace In String

[Solved] To Remove Whitspace In String | Swift - Code Explorer | yomemimo.com
Question : to remove whitspace in string

Answered by : xerothermic-xenomorph-l5mskt037ffk

# Python3 code to remove whitespace
def remove(string): return "".join(string.split())
# Driver Program
string = ' g e e k '
print(remove(string))

Source : https://www.geeksforgeeks.org/python-remove-spaces-from-a-string/ | Last Update : Fri, 10 Jun 22

Answers related to to remove whitspace in string

Code Explorer Popular Question For Swift