#include <bits/stdc++.h> using namespace std; vector<int> z(vector<int> x,vector<int> y){ vector<int> s(x.size(),0); int sum=0; for(int i=0;i<x.size();i++){ if(i>=y.size()){ y[i]=0; } if(x[i]<y[i]){ x[i]=x[i]+10; x[i+1]-=1; } s[i]=x[i]-y[i]; } while(s.size()>1&&s.back()==0){ s.pop_back(); } for(int k=s.size()-1;k>=0;k--){ cout<<s[k]; } return s; } int main(){ string a,b; cin>>a>>b; vector<int> c,d,s; for(int i=a.size()-1;i>=0;i--){ c.push_back(a[i]-'0'); } for(int j=b.size()-1;j>=0;j--){ d.push_back(b[j]-'0'); } z(c,d); return 0; }