Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if(c)w=min(w,1+dyn(n-1,b,c-1));
- if(c&&u>2)w=min(w,4+dyn(n-1,b+1,c-1));
- if(b>1)w=min(w,2+dyn(n-1,b-2,c));
- if(u>7)w=min(w,8+dyn(n-1,b,c));
- if(b&&u>2)w=min(w,4+dyn(n-1,b-1,c));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement