functionremoveQuestionMarks(input){if(typeofinput!=="string"){thrownewTypeError("First argument expected to be a string");}returninput.split("?").join("");}console.log(removeQuestionMarks("hello?"));// "hello"console.log(removeQuestionMarks("hmm? hello??"));// "hmm hello"console.log(removeQuestionMarks("hmm? hello?? can i speak to the manager?"));// "hmm hello can i speak to the manager"console.log(removeQuestionMarks("?? is anybody there???"));// " is anybody there"
By the name of the title in my notifications, I really though that the challenge would be to write a challenge and submit the best to the Dev.to team as they were running out of ideas. Haha!
By the name of the title in my notifications, I really though that the challenge would be to write a challenge and submit the best to the Dev.to team as they were running out of ideas. Haha!
Please submit challenge ideas! Simply email yo+challenge@dev.to with any proposals and we'll give you credit when we post it :)
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
JavaScript
Here is my take to the challenge:
Source-Code
Available online.
Side-note
By the name of the title in my notifications, I really though that the challenge would be to write a challenge and submit the best to the Dev.to team as they were running out of ideas. Haha!
Tomorrows challenge:
Oh, sounds sexy. I love it! Haha.
Please submit challenge ideas! Simply email yo+challenge@dev.to with any proposals and we'll give you credit when we post it :)