QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#394478#3164. All KillmaoyitingWA 6ms4348kbC++14288b2024-04-20 15:09:212024-04-20 15:09:21

Judging History

你现在查看的是最新测评结果

  • [2024-04-20 15:09:21]
  • 评测
  • 测评结果:WA
  • 用时:6ms
  • 内存:4348kb
  • [2024-04-20 15:09:21]
  • 提交

answer

#include<bits/stdc++.h>
using namespace std;
const int N=1e5+5;
int n,t,a[N],ans;
signed main(){
	scanf("%d%d",&n,&t);
	for(int i=1;i<=n;i++)
		scanf("%d",&a[i]),t-=a[i];
	ans=t+1;
	for(int i=1,s=0;i<n;i++)
		ans=1ll*ans*(n+t+1-i+(s+=a[i]));
	printf("%d\n",ans);
	return 0;
}

详细

Test #1:

score: 100
Accepted
time: 1ms
memory: 3832kb

input:

3 5
1
2
1

output:

60

result:

ok single line: '60'

Test #2:

score: 0
Accepted
time: 0ms
memory: 3916kb

input:

5 5
1
1
1
1
1

output:

1296

result:

ok single line: '1296'

Test #3:

score: -100
Wrong Answer
time: 6ms
memory: 4348kb

input:

99227 20385292
7
54
381
4
5
81
784
4
58
5
952
707
62
88
73
88
51
6
37
895
4
442
10
924
2
34
139
938
95
460
648
5
935
933
8
3
53
275
316
232
5
221
4
290
31
17
19
984
498
49
666
295
928
6
5
6
79
48
7
2
241
6
790
8
1
7
4
280
387
4
59
12
8
92
8
69
24
999
61
4
9
296
62
3
79
46
465
10
2
8
10
971
7
6
366
5...

output:

0

result:

wrong answer 1st lines differ - expected: '637667063', found: '0'