QwQ,[大雾],出了个奇奇怪怪的CE
查看原帖
QwQ,[大雾],出了个奇奇怪怪的CE
935012
Max6700楼主2023/6/18 18:06
#include<bits/stdc++.h>
using namespace std;

struct aa
{
    string a[100000];
    int x;
}s[1001];

int n,m;

int main(){
    
    cin>>n;
    
    for(int i=1;i<=n;i++)
    {
        cin>>s[i].x;
        for(int j=1;j<=s[i].x;j++)cin>>s[i].a[j];
    }
    cin>>m;
    for(int i=1;i<=m;i++)
    {
        string std;
        cin>>std;
        for(int j=1;j<=n;j++)
            for(int k=1;k<=s[j].x;k++)
                if(s[j].a[k]==std)
                {
                    cout<<j<<" ";
                    break;
                    
                }
                
        cout<<"\n";
    }
    
    
    return 0;
}

e记录

2023/6/18 18:06
加载中...