답안 #72409

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
72409 2018-08-26T07:50:31 Z IDxTree(#2155, TAMREF, imeimi2000, Diuven) 코코넛 젤리 음료수 (FXCUP3_nectar) C++17
15 / 100
42 ms 740 KB
#include <bits/stdc++.h>
using namespace std;
typedef pair<int, int> pii;
typedef long long ll;
const int inf=2e9;

int n, j, r, t;
ll A[1010];

int main(){
	ios::sync_with_stdio(0); cin.tie(0);
	cin>>n>>j>>r>>t;
	assert(n<=1000 && t<=3000);
	for(int i=1; i<=n; i++) A[i]=j;
	for(int _=1; _<=t; _++){
		for(int i=n-1; i>=1; i--){
			int x=(A[i]+r-1)/r;
			A[i+1]+=x, A[i]-=x;
		}
	}
	for(int i=1; i<=n; i++) cout<<A[i]<<'\n';
	return 0;
}
# 결과 실행 시간 메모리 Grader output
1 Correct 2 ms 248 KB Output is correct
2 Correct 2 ms 356 KB Output is correct
3 Correct 3 ms 564 KB Output is correct
4 Correct 3 ms 564 KB Output is correct
5 Correct 2 ms 564 KB Output is correct
6 Correct 3 ms 564 KB Output is correct
7 Correct 26 ms 564 KB Output is correct
8 Correct 42 ms 564 KB Output is correct
9 Correct 42 ms 596 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 2 ms 248 KB Output is correct
2 Correct 2 ms 356 KB Output is correct
3 Correct 3 ms 564 KB Output is correct
4 Correct 3 ms 564 KB Output is correct
5 Correct 2 ms 564 KB Output is correct
6 Correct 3 ms 564 KB Output is correct
7 Correct 26 ms 564 KB Output is correct
8 Correct 42 ms 564 KB Output is correct
9 Correct 42 ms 596 KB Output is correct
10 Runtime error 2 ms 740 KB Execution killed with signal 11 (could be triggered by violating memory limits)
11 Halted 0 ms 0 KB -