#include long min(long n, long a[], long memo[]){ long i; long shou = 10000000; for(i=0;i a[i]){ shou = a[i]; memo[i] = a[i]; } } return shou; } int main(void){ long n,m,x,y; long a[100000]; long i,memo[100000]; long long sum = 0; scanf("%ld%ld%ld%ld",&n,&m,&x,&y); long count = n; for(i=0;i= x) memo[i] = a[i]; sum += a[i]; } while(m < count){ long long temp = min(n,a,memo); if(temp == 10000000){ printf("Handicapped\n"); return 0; } sum -= temp; count--; //printf("%d:sum=%d ",temp,sum); } printf("%lld\n",sum); return 0; }