public String add(String a, String b){
        if(a == null) return b;
        if(b == null) return a;
        StringBuilder result = new StringBuilder();
        a = new StringBuilder(a).reverse().toString();
        b = new StringBuilder(b).reverse().toString();
        int index = 0;
        int extra = 0;
        while(index < a.length() || index < b.length()){
            int first = index < a.length() ? Character.getNumericValue(a.charAt(index)) : 0;
            int second = index < b.length() ? Character.getNumericValue(b.charAt(index)) : 0;
            int digit = (first + second + extra) % 10;
            extra = (first + second + extra) / 10;
            result.append(digit);
            index++;
        }
        if(extra > 0)
            result.append(extra);
        return result.reverse().toString();
    }