Four points in a plane form a square if and only if the four sides have equal length and if the two diagonals have equal length.
The following sequences of four points each form a square:
(0,0), (0,1), (1,1), (1,0)
(0,0), (1,1), (0,1), (1,0)
(0,0), (2,1), (3,-1), (1, -2)
Note that the points can be given in any order and that the sides of a square do not need to be parallel to the $$X$$ and $$Y$$ axis. All sequences of four points given below do not form a square, but respectively a rectangle, a rhombus and a degenerated case.
(0,0), (0,2), (3,2), (3,0)
(0,0), (3,4), (8,4), (5,0)
(0,0), (0,0), (1,1), (0,0)
Eight real valued numbers, each on a separate line. These numbers are respectively the $$x$$ and $$y$$ coordinates of point $$a$$, the $$x$$ and $$y$$ coordinates of point $$b$$, the $$x$$ and $$y$$ coordinates of point $$c$$ and the $$x$$ and $$y$$ coordinates of point $$d$$. You may assume that the four given points will never coincide, so this specific case does not need to be checked explicitly. Pay attention when comparing real valued numbers! In preparation, read the discussion on the flaws of floating point numbers in The Python Tutorial1 or watch the video beneath where Pythia gives some tips on working with floating point numbers.
A single line containing the text square if the four points represent a square, and the text not a square if this is not the case.
Input:
0.0
0.0
0.0
1.0
1.0
1.0
1.0
0.0
Output:
square
Input:
0.0
0.0
3.0
4.0
8.0
4.0
5.0
0.0
Output:
not a square