':type num1: str
:type num2: str
:rtype: str'

def addStrings(self, num1, num2):

    result = []
    (i, j, carry) = ((len(num1) - 1), (len(num2) - 1), 0)
    while ((i >= 0) or (j >= 0) or carry):
        if (i >= 0):
            carry += (ord(num1[i]) - ord('0'))
            i -= 1
        if (j >= 0):
            carry += (ord(num2[j]) - ord('0'))
            j -= 1
        result.append(str((carry % 10)))
        carry /= 10
    result.reverse()
    return ''.join(result)
