Graph connectivity
A connected undirected graph is provided.
You will be asked to handle queries that check if the graph remains connected after removing a specified small set of edges.
Input
The first line of the input contains two integers, N and M (1 ≤ N ≤ 10000, 1 ≤ M ≤ 100000), representing the number of vertices and edges, respectively. The following M lines describe the edges. Each line contains two integers, a and b, indicating the vertices connected by that edge. The graph does not contain loops or multiple edges. Vertices are numbered starting from one, and edges are listed in the order they appear in the input.
The next line contains a single integer K (1 ≤ K ≤ 100000), representing the number of queries. Each of the following K lines describes a query. A query begins with an integer C (1 ≤ C ≤ 4), indicating the number of edges in the query, followed by C integers specifying the edges to be removed. All edges in a query are distinct.
Output
For each query, output a single line. The i-th line should read "Connected" if the graph remains connected after removing the specified edges, and "Disconnected" if it does not.