<p>Given a string <code>s</code> containing an out-of-order English representation of digits <code>0-9</code>, return <em>the digits in <strong>ascending</strong> order</em>.</p>

<p>&nbsp;</p>
<p><strong class="example">Example 1:</strong></p>
<pre><strong>Input:</strong> s = "owoztneoer"
<strong>Output:</strong> "012"
</pre><p><strong class="example">Example 2:</strong></p>
<pre><strong>Input:</strong> s = "fviefuro"
<strong>Output:</strong> "45"
</pre>
<p>&nbsp;</p>
<p><strong>Constraints:</strong></p>

<ul>
	<li><code>1 &lt;= s.length &lt;= 10<sup>5</sup></code></li>
	<li><code>s[i]</code> is one of the characters <code>[&quot;e&quot;,&quot;g&quot;,&quot;f&quot;,&quot;i&quot;,&quot;h&quot;,&quot;o&quot;,&quot;n&quot;,&quot;s&quot;,&quot;r&quot;,&quot;u&quot;,&quot;t&quot;,&quot;w&quot;,&quot;v&quot;,&quot;x&quot;,&quot;z&quot;]</code>.</li>
	<li><code>s</code> is <strong>guaranteed</strong> to be valid.</li>
</ul>

class Solution:
    def originalDigits(self, s: str) -> str:
        nums = []
        charCounter = Counter(s)

        def helper(uniqueChar, num, numWord):
            numCount = charCounter[uniqueChar]
            if numCount > 0:
                nums.extend([str(num)]*numCount)
                charWordCounter = Counter(numWord)
                for char in charWordCounter:
                    charCounter[char] -= numCount*charWordCounter[char]

        # Process evens 1st
        helper("z", 0, "zero")
        helper("w", 2, "two")
        helper("u", 4, "four")
        helper("x", 6, "six")
        helper("g", 8, "eight")

        # With evens processed, do odds
        helper("o", 1, "one")
        helper("t", 3, "three")
        helper("f", 5, "five")
        helper("s", 7, "seven")
        helper("i", 9, "nine")

        return "".join(sorted(nums))
16900