#include using namespace std; template inline void chmin(T1 &a,T2 b){if(a>b) a=b;} template inline void chmax(T1 &a,T2 b){if(a>n>>x>>y>>z; vector as(n); for(int i=0;i>as[i]; for(int i=0;i cs({10000,5000,1000}); vector vs({z,y,x}); for(int t=0;t<3;t++){ int c=cs[t],v=vs[t]; for(int i=0;i(n,0)) cout<<"Yes"<