QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#715518#9587. 结课风云carboxylBaseWA 0ms3608kbC++23668b2024-11-06 12:22:442024-11-06 12:22:45

Judging History

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

  • [2024-11-06 12:22:45]
  • 评测
  • 测评结果:WA
  • 用时:0ms
  • 内存:3608kb
  • [2024-11-06 12:22:44]
  • 提交

answer

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define int long long

void solve(){
	int n;
	cin >> n;
	int a,b,c;
	cin >> a >> b >> c;
	int cnt = 0;
	vector<int> x(n),y(n);
	for (int i = 0;i<n;i++){
		cin >> x[i] >> y[i];
	}
	int d;
	cin >> d;
	for (int i = 0;i<n;i++){
		if (x[i] + y[i] >=c){
			continue;
		}
		y[i] += d;
		if (y[i] > b){
			y[i] = b;
		}
		if (x[i] + y[i] >= c){
			cnt++;
		}
	}
	cout << cnt;
    return;
}

signed main(){
    // freopen("input.txt","r",stdin);
    ios::sync_with_stdio(0),cin.tie(0),cout.tie(0);
    int _ = 1;
    while (_--){
        solve();
    }
    return 0;
}

详细

Test #1:

score: 100
Accepted
time: 0ms
memory: 3572kb

input:

5
40 60 60
20 25
10 40
25 30
35 50
40 60
10

output:

2

result:

ok single line: '2'

Test #2:

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

input:

1
0 100 0
0 52
0

output:

0

result:

ok single line: '0'

Test #3:

score: -100
Wrong Answer
time: 0ms
memory: 3508kb

input:

1000
100 0 100
48 0
43 0
67 0
9 0
97 0
2 0
35 0
47 0
81 0
29 0
96 0
19 0
100 0
14 0
79 0
89 0
37 0
54 0
93 0
9 0
23 0
44 0
37 0
99 0
5 0
39 0
31 0
24 0
65 0
87 0
100 0
100 0
51 0
62 0
92 0
33 0
73 0
53 0
49 0
65 0
29 0
44 0
44 0
29 0
80 0
60 0
79 0
84 0
16 0
99 0
14 0
68 0
96 0
42 0
8 0
24 0
80 0
17...

output:

0

result:

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