uses
  SysUtils;

var
  i,j,k:longint;
  n,prom,w,ost:longint;
  len1,len2,len3,sum,len_res1,len_res2:longint;
  a,b,c,res1,res2:array[1..100]of longint;
  ch:array[1..300] of char;
function max(a,b:longint):longint;
begin
  if a>b then max:=a else max:=b;
end;

begin
assign(input,'d.in');
reset(input);
i:=0;
while not eof do
begin
     inc(i);
     read(ch[i]);
end;
close(input);
n:=i;
k:=1;
i:=1;
while  ch[i]<>' ' do
begin
  c[i]:=strtoint(ch[i]);
  inc(i);
end;
len3:=i-1;
inc(i);
while  ch[i]<>' ' do
begin
  a[k]:=strtoint(ch[i]);
  inc(i);
  inc(k);
end;
inc(i);
len1:=k-1;
k:=0;
while i<=n do
begin
    inc(k);
    b[k]:=strtoint(ch[i]);
    inc(i);
end;
len2:=k;
sum:=len1+len2+len3;

for i:=1 to (len1 div 2) do
begin
     w:=a[i];
     a[i]:=a[len1-i+1];
     a[len1-i+1]:=w;
end;

for i:=1 to (len2 div 2) do
begin
     w:=b[i];
     b[i]:=b[len2-i+1];
     b[len2-i+1]:=w;
end;

for i:=1 to (len3 div 2) do
begin
     w:=c[i];
     c[i]:=c[len3-i+1];
     c[len3-i+1]:=w;
end;

for i:=1 to len3 do
begin
      k:=i+1;
      if c[i]>=a[i] then
      res1[i]:=c[i]-a[i] else
      begin
          while (c[k]=0) and (k<=len3) do
          begin
              c[k]:=9;
              inc(k);
          end;
          dec(c[k]);
          res1[i]:=10+c[i]-a[i]
      end;
end;
len_res1:=len3;
sum:=sum+len_res1+len_res2;
for i:=len3 downto 1  do
begin
     if res1[i]=0 then dec(len_res1)else break;
end;
sum:=sum+len_res1+len_res2;
n:=max(len_res1,len2);
ost:=0;
len_res2:=n;
for i:=1 to n do
begin
      res2[i]:=(res1[i]+b[i]+ost) mod 10;
      ost:=(res1[i]+b[i]+ost) div 10;
end;
if ost>0 then
begin
  res2[n+1]:=ost;
  inc(len_res2);
end;
assign(output,'d.out');
rewrite(output);
for i:=len_res2 downto 1 do
write(res2[i]);
close(output);
end.

