| 22026 | 2026-01-14 13:13:40 | Bencu | Bizonyítás | cpp17 | Compilation error |
#include <bits/stdc++.h>
using namespace std;
ifstream f("be.in");
int n,q;
bool a[501][501];
int main()
{
std::sync_with_stdio(0);
cin.tie(0);
cin>>n>>q;
for (int v=1; v<=q; v++) {
int x,z,y;
cin>>z>>x>>y;
if (z==1) {
a[x][y]=1;
for (int i=1; i<=n; i++) {
if (a[y][i]==1) {a[x][i]=1; for (int j=1; j<=n; j++) if (a[j][x]==1) a[j][i]=1;}
if (a[i][x]==1) {a[i][y]=1; for (int j=1; j<=n; j++) if (a[y][j]==1) a[i][j]=1;}
}
}
else {
if (a[x][y]==1) cout<<"IGEN"<<endl;
else cout<<"NEM"<<endl;
}
}
return 0;
}
open /var/local/lib/isolate/443/box/a.out: no such file or directory
main.cpp: In function 'int main()':
main.cpp:9:10: error: 'sync_with_stdio' is not a member of 'std'
9 | std::sync_with_stdio(0);
| ^~~~~~~~~~~~~~~