Kalvin John Ian Helvik IV and Karl James Ingram Helvik III are second cousins and the kings of two neighbouring countries, Aastria and Abstria. One hundred years ago these lands formed a single kingdom, but when old King Helvik died he left the country to his twin sons, Ian and Ingram. Nobody knew how to divide it, until it was proposed to split the land into two equal parts. The task proved impossibly hard, five attempts to solve it failed, and a bloody civil war broke out.
The war lasted seven years and ended with the Northeastern Enormously Ragged Combat. By its final decree, two new countries rose in place of the old one, one for Ian and one for Ingram. But the two countries had unequal areas, so within three years war began again.
After ninety years of fighting, both countries were exhausted. Realizing that neither would survive another year of war, the two kings simultaneously sent envoys with offers of peace and agreed to unite their lands once more. The reunited country of Aastria and Abstria was named Aabstria.
In old manuscripts you have found several descriptions of the countries' borders. Each description lists the positions of one country's boundary monuments, given in clockwise or counterclockwise order along the border. Different sources disagree, and in some of them the border does not even form a polygon. Given the monument positions of all three countries, the following statements must hold:
Write a program that checks whether all of these statements are true.
The first line contains an integer $n_a$ ($1 \le n_a \le 10000$), the number of boundary monuments of Aastria. Each of the next $n_a$ lines contains two integers, the coordinates of one monument, listed in clockwise or counterclockwise order along the border.
After that, the descriptions of Abstria and then Aabstria are given in the same format.
Every coordinate has absolute value at most $10^5$. Two boundary monuments may coincide only if they belong to different countries.
Print a single line containing exactly one of the following strings:
Aastria is not a polygon;Abstria is not a polygon;Aabstria is not a polygon;Aastria and Abstria intersect;The union of Aastria and Abstria is not equal to Aabstria;OK.