The FME graph (1) P62285


Statement
 

pdf   zip

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.

Public test cases
  • Input

    4 4
    142857 42
    2 2
    1000000000 1000000000
    

    Output

    connected
    disconnected
    you've been trolled
    impossible to know
    
  • Information
    Author
    Ferran Alet
    Language
    English
    Translator
    Original language
    Catalan
    Other languages
    Catalan
    Official solutions
    C++
    User solutions
    C++