Skip to content

Latest commit

 

History

History

remove-vowels-from-a-string

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 

< Previous                  Next >

Given a string S, remove the vowels 'a', 'e', 'i', 'o', and 'u' from it, and return the new string.

 

Example 1:

Input: "leetcodeisacommunityforcoders"
Output: "ltcdscmmntyfrcdrs"

Example 2:

Input: "aeiou"
Output: ""

 

Note:

  1. S consists of lowercase English letters only.
  2. 1 <= S.length <= 1000

Related Topics

[String]

Similar Questions

  1. Reverse Vowels of a String (Easy)

Hints

Hint 1 How to erase vowels in a string?
Hint 2 Loop over the string and check every character, if it is a vowel ignore it otherwise add it to the answer.