QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#648084 | #8102. Mall | rotcar07 | Compile Error | / | / | Python3 | 470b | 2024-10-17 16:57:12 | 2024-10-17 16:57:14 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
constexpr int maxn=1e3+5;
int col[maxn];
int main(){
int n,m;cin>>n>>m;
for(int i=1;i<=n;i++){
int k;cin>>k;
for(int j=1,x;j<=k;j++) cin>>x,col[x]=i;
}
bool f=1;for(int i=1;i<=m;i++) f&=!!col[i];
if(!f) cout<<"NO\n";
else{
cout<<"YES\n";
for(int i=1;i<=m;i++) cout<<i<<' ';cout<<'\n';
for(int i=1;i<=m;i++) cout<<col[i]<<' ';cout<<'\n';
}
}
Details
File "answer.code", line 2 using namespace std; ^^^^^^^^^ SyntaxError: invalid syntax