QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#422377 | #8724. September | Physics212303 | 0 | 0ms | 0kb | C++17 | 630b | 2024-05-27 13:24:41 | 2024-05-27 13:24:43 |
answer
#include<bits/stdc++.h>
using namespace std;
int solve(int n,int m,vector<int> f,vector<vector<int> > s){
int c=0;
vector g(m,vector<set<int> >(n));
vector<set<int> > v(m);
for(int i=0;i<m;i++)
for(int j=1;j<n;j++)
g[i][f[j]].emplace(j),v[j].emplace(f[j]);
vector<double> a(m);
for(int i=0;i<n-1;i++){
bool b=true;
for(int j=0;j<m;j++){
a[j]+=cos(s[j][i]);
g[j][f[s[j][i]]].erase(s[j][i]);
if(g[j][f[s[j][i]]].empty())
v[j].erase(f[s[j][i]]);
b&=v[j].empty();
}
for(int j=1;j<m&&b;j++)
b&=a[j]==a[j-1];
c+=b;
}
return c;
}
详细
Subtask #1:
score: 0
Runtime Error
Test #1:
score: 0
Runtime Error
input:
txy4h26c1rm1uv8tr3eonahd67u8h56x 4 7 1 0 0 2 3 3 5 1 6 4 3 5 2 10 1 0 1 2 0 3 0 5 4 8 9 7 6 8 4 5 3 2 1 7 1 0 0 0 1 3 0 2 4 1 6 5 3 6 1 0 0 1 1 3 4 5 2 3 1
output:
result:
Subtask #2:
score: 0
Skipped
Dependency #1:
0%
Subtask #3:
score: 0
Runtime Error
Test #17:
score: 0
Runtime Error
input:
txy4h26c1rm1uv8tr3eonahd67u8h56x 53 10 1 0 1 2 3 4 5 6 7 8 9 8 7 6 5 4 3 2 1 10 1 0 1 2 3 4 5 6 7 8 9 7 8 5 6 4 3 2 1 10 1 0 1 2 3 4 5 6 7 8 8 9 7 5 6 3 2 4 1 10 1 0 1 2 3 4 5 6 7 8 8 9 6 7 5 4 3 2 1 10 1 0 1 2 3 4 5 6 7 8 8 9 7 5 6 3 4 2 1 10 1 0 1 2 3 4 5 6 7 8 9 8 7 6 5 4 2 3 1 10 1 0 1 2 3 4 5 6...
output:
result:
Subtask #4:
score: 0
Skipped
Dependency #1:
0%
Subtask #5:
score: 0
Skipped
Dependency #3:
0%
Subtask #6:
score: 0
Skipped
Dependency #1:
0%
Subtask #7:
score: 0
Skipped
Dependency #3:
0%
Subtask #8:
score: 0
Skipped
Dependency #1:
0%
Subtask #9:
score: 0
Skipped
Dependency #3:
0%
Subtask #10:
score: 0
Skipped
Dependency #1:
0%