From c349ee0d3e35d80ac026bdbe267214193f08174c Mon Sep 17 00:00:00 2001 From: Deven <63876261+devenperez@users.noreply.github.com> Date: Wed, 10 Sep 2025 20:57:33 -0400 Subject: [PATCH] Create README - LeetHub --- 2785-sort-vowels-in-a-string/README.md | 35 ++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 2785-sort-vowels-in-a-string/README.md diff --git a/2785-sort-vowels-in-a-string/README.md b/2785-sort-vowels-in-a-string/README.md new file mode 100644 index 0000000..5691386 --- /dev/null +++ b/2785-sort-vowels-in-a-string/README.md @@ -0,0 +1,35 @@ +

2785. Sort Vowels in a String

Medium


Given a 0-indexed string s, permute s to get a new string t such that:

+ + + +

Return the resulting string.

+ +

The vowels are 'a', 'e', 'i', 'o', and 'u', and they can appear in lowercase or uppercase. Consonants comprise all letters that are not vowels.

+ +

 

+

Example 1:

+ +
+Input: s = "lEetcOde"
+Output: "lEOtcede"
+Explanation: 'E', 'O', and 'e' are the vowels in s; 'l', 't', 'c', and 'd' are all consonants. The vowels are sorted according to their ASCII values, and the consonants remain in the same places.
+
+ +

Example 2:

+ +
+Input: s = "lYmpH"
+Output: "lYmpH"
+Explanation: There are no vowels in s (all characters in s are consonants), so we return "lYmpH".
+
+ +

 

+

Constraints:

+ +