#423
Reconstruct Original Digits from English
specialist · 900 · lc medium +31 · verified · 52.7% accepted · 892 likes · top 43%
Description
The string s contains letters scrambled from English digit names ("zero" through "nine"). Determine how many times each digit 0–9 appears in s and return all digits in ascending order as a single string.
Example 1:
Input: s = "owoztneoer"
Output: "012"
Example 2:
Input: s = "fviefuro"
Output: "45"
Code
1
2
3