import java.util.ArrayList; import java.util.Arrays; import java.util.Scanner; class Main { public static void main(String[] args) { new Main().run(); } long gcd(long a,long b) { return a==0?b:gcd(b%a,a); } long lcm(long a,long b) { return a/gcd(a,b)*b; } int dfs(int cur,int par,ArrayList[] g,boolean[] vis) { if(vis[cur])return 0; int sz=1; vis[cur]=true; for(int dst:g[cur]) { if(dst==par)continue; sz+=dfs(dst,cur,g,vis); } return sz; } void run() { Scanner sc=new Scanner(System.in); int N=sc.nextInt(); int K=sc.nextInt(); ArrayList[] g=new ArrayList[N]; for(int i=0;i(); int[] ord=new int[N]; for(int i=0;i