The Python Oracle

Is there a simple way to remove multiple spaces in a string?

Become part of the top 3% of the developers by applying to Toptal https://topt.al/25cXVn

--

Music by Eric Matyas
https://www.soundimage.org
Track title: Unforgiving Himalayas Looping

--

Chapters
00:00 Question
00:27 Accepted answer (Score 841)
00:38 Answer 2 (Score 783)
01:08 Answer 3 (Score 129)
01:28 Answer 4 (Score 65)
06:02 Thank you

--

Full question
https://stackoverflow.com/questions/1546...

Answer 1 links:
[hhsaffar]: https://stackoverflow.com/users/1380151/...

Answer 2 links:
[PEPĀ 8]: https://www.python.org/dev/peps/pep-0008/
[mentioned by user ]: https://stackoverflow.com/questions/1546...

Answer 3 links:
[11 paragraphs, 1000 words, 6665 bytes of Lorem Ipsum]: http://www.lipsum.com
[Keep in mind that the main ]: http://docs.python.org/2/library/timeit....
[remember the mantra]: http://c2.com/cgi/wiki?MakeItWorkMakeItR...

--

Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...

--

Tags
#python #regex #string

#avk47