#include using namespace std; signed main(){ int aw,ab,bw,bb,c,d;cin>>aw>>ab>>bw>>bb>>c>>d; int A=max(c-ab,0); aw-=A;bw+=A; cout<