Python3 very simple, no sorting
\nclass Solution:\n    def sortString(self, s: str) -> str:\n        freq = [0] * 26\n        for ch in s:\n            freq[ord(ch) - ord(\'a\')] += 1\n       
```\nclass Solution:\n    def sortString(self, s: str) -> str:\n        freq = [0] * 26\n        for ch in s:\n            freq[ord(ch) - ord(\'a\')] += 1\n        ret = \'\'\n        a = ord(\'a\')\n        while len(ret) < len(s):\n            i = 0\n            while i < 26:\n                if freq[i]:\n                    ret += chr(i + a)\n                    freq[i] -= 1\n                i += 1\n            i = 25\n            while i > -1:\n                if freq[i]:\n                    ret += chr(i + a)\n                    freq[i] -= 1\n                i -= 1\n        return ret\n```
[]