Given a multiple line sentence or statement the task is to convert the whole statement in a
single line. See the example below.
Input : Hello welcome to geeksforgeeks. Output : Hello welcome to geeksforgeeks. Remove the new line between Hello and geeksforgeeks. Input : I love geeksforgeeks Output : I love geeksforgeeks
The idea is to use str_replace()
- Remove characters from a numeric string such that string becomes divisible by 8
- How to remove the first character of string in PHP?
- How to remove extension from string in PHP?
- Program to remove consonants from a String
- How to remove portion of a string after a certain character in PHP?
- How to remove line breaks from the string in PHP?
- Remove characters from string that appears strictly less than K times
- Form N-copy string with add, remove and append operations
- Set the limit of text length to N lines using CSS
- PHP Ds\Set remove() Function
- Remove characters that appear more than k times
- jQuery | Remove Elements
- Remove border from IFrame using CSS
- PHP | Ds\Deque remove() Function
- PHP | Ds\Vector remove() Function
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.