message: Update decrypt-string-from-alphabet-to-integer-mapping.py
diff: @@ -45,3 +45,20 @@ class Solution2(object):
  result.append(alpha(s[i]))
  i -= 1
  return "".join(reversed(result))
  +
  +# Time: O(n)
  +# Space: O(n)
  +import re
  +
  +
  +# regex solution
  +class Solution3(object):
  + def freqAlphabets(self, s):
  + """
  + :type s: str
  + :rtype: str
  + """
  + def alpha(num):
  + return chr(ord('a') + int(num)-1)
  +
  + return "".join(alpha(i[:2]) for i in re.findall(r"\d\d#|\d", s))
  