QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#664520 | #7157. Bikes vs Cars | Khiem# | 0 | 1ms | 4496kb | C++14 | 615b | 2024-10-21 20:57:42 | 2024-10-21 20:57:43 |
answer
#include <bits/stdc++.h>
using namespace std;
const int N = 505;
int C[N][N], B[N][N];
signed main(){
int n, W; scanf("%d %d", &n, &W);
for(int i = 1; i<n; ++i){
for(int j = 0; j<i; ++j){
scanf("%d", &C[i][j]);
}
}
for(int i = 1; i<n; ++i){
for(int j = 0; j<i; ++j){
scanf("%d", &B[i][j]);
}
}
if(W < B[0][1] || W < C[0][1]){ puts("NO"); return 0;}
printf("%d\n", 2*(n-1));
for(int i = 1; i<n; ++i){
printf("%d %d %d\n", i-1, i, B[0][0]);
printf("%d %d %d\n", i-1, i, W - C[0][0]);
}
}
Details
Tip: Click on the bar to expand more detailed information
Subtask #1:
score: 0
Wrong Answer
Test #1:
score: 0
Wrong Answer
time: 1ms
memory: 3904kb
input:
14 1000000 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 49...
output:
26 0 1 0 0 1 1000000 1 2 0 1 2 1000000 2 3 0 2 3 1000000 3 4 0 3 4 1000000 4 5 0 4 5 1000000 5 6 0 5 6 1000000 6 7 0 6 7 1000000 7 8 0 7 8 1000000 8 9 0 8 9 1000000 9 10 0 9 10 1000000 10 11 0 10 11 1000000 11 12 0 11 12 1000000 12 13 0 12 13 1000000
result:
wrong answer Min Max 1 - 0 not equal aij, is 0, should be 505815
Subtask #2:
score: 0
Skipped
Dependency #1:
0%
Subtask #3:
score: 0
Wrong Answer
Test #16:
score: 0
Wrong Answer
time: 1ms
memory: 3912kb
input:
14 1000000 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 494185 49...
output:
26 0 1 0 0 1 1000000 1 2 0 1 2 1000000 2 3 0 2 3 1000000 3 4 0 3 4 1000000 4 5 0 4 5 1000000 5 6 0 5 6 1000000 6 7 0 6 7 1000000 7 8 0 7 8 1000000 8 9 0 8 9 1000000 9 10 0 9 10 1000000 10 11 0 10 11 1000000 11 12 0 11 12 1000000 12 13 0 12 13 1000000
result:
wrong answer Min Max 1 - 0 not equal aij, is 0, should be 505815
Subtask #4:
score: 0
Wrong Answer
Test #39:
score: 0
Wrong Answer
time: 0ms
memory: 4496kb
input:
163 1 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 1 1 0 0 0 1 0 1 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1 1 0 0 ...
output:
324 0 1 0 0 1 1 1 2 0 1 2 1 2 3 0 2 3 1 3 4 0 3 4 1 4 5 0 4 5 1 5 6 0 5 6 1 6 7 0 6 7 1 7 8 0 7 8 1 8 9 0 8 9 1 9 10 0 9 10 1 10 11 0 10 11 1 11 12 0 11 12 1 12 13 0 12 13 1 13 14 0 13 14 1 14 15 0 14 15 1 15 16 0 15 16 1 16 17 0 16 17 1 17 18 0 17 18 1 18 19 0 18 19 1 19 20 0 19 20 1 20 21 0 20 21 ...
result:
wrong answer Min Max 1 - 0 not equal aij, is 0, should be 1
Subtask #5:
score: 0
Skipped
Dependency #2:
0%
Subtask #6:
score: 0
Skipped
Dependency #1:
0%