+ 1
String Manipulating
I have three string and I’m trying to write a function that solve my problem. It take a string with some extra space around and I’m trying to cleaning it up so it looks pretty nice. Between each word it has one space until the last two words. It depends how many spaces is between them it returns it just like it passed in. See my example: https://code.sololearn.com/cgSraXYf0fiS/?ref=app
3 Respuestas
0
https://code.sololearn.com/c1lm0XjwZzLO/?ref=app
Here is the solution
+ 1
Thats not the case in here Ani Jona 🕊. If i wanna to replace all spaces this woulf be good idea. But i wanna replace all extra spaces except the last one. I wanna to keep the spaces.
0
Ani Jona 🕊 I appreciate your time :)