#include using namespace std; //#include //using namespace atcoder; using ll=long long; using Graph=vector>; #define MAX 200003 #define MOD 998244353 #define INF 1000000000 int main(){ int N; cin>>N; vector> a(N,vector(N,-1)); for(int k=0;k