#include long long x[100000]; int main(int argc, char const *argv[]){ long long n,d,k,i,c,max=0,sell,min_i,next_min; scanf("%lld %lld %lld",&n,&d,&k); for(i=0;i=n) break; if(max