The FME graph (1)

A rookie is curious about what the FME graph is. After some days, he learns that it is an undirected graph where the vertices are the FME students, and there is an edge between xx and yy if they had an affair at some moment. There is no more than one edge between each pair xx and yy, nor edges of the kind xx xx.

Suppose that someone gives you the number of vertices nn and the number of edges mm. With this information, can you tell if the graph is connected, if it is not, or that you are being fooled?

Input

Input consists of several cases. Every case has the supposed numbers of vertices and edges of an undirected graph. You can assume 2n1092 \le n \le 10^9 and 0m1090 \le m \le 10^9.

Output

For every case, tell if you can assure that the graph is connected, if you can assure that the graph is not connected, if it is impossible that such a graph exists, or if we are in none of those situations.

Problem information

Author: Ferran Alet

Generation: 2026-01-25T11:13:01.138Z

© Jutge.org, 2006–2026.
https://jutge.org