Submission
Status:
PPPPPPPPPPPPPPPPPPPP
Subtask/Task Score:
100/100
Score: 100
User: ThreeDee
Problemset: Slowly Express
Language: c
Time: 0.002 second
Submitted On: 2025-12-06 12:43:53
#include <stdio.h>
int main(){
int n=0,t=0,w=0;
while(1){
t=0;
scanf("%d",&n);
if(n<0)break;
w+=n;
while(w>=500){
t++;
if(w>=800)w-=800;
else w=0;
}
printf("%d\n",t);
}
return 0;
}