|
|||||||||||||||||||
|
SPOJ time: 2012-05-25 02:29:43 |
Inside or outsideProblem code: HS11IO
Given an ellipse E and a point P on the plane decide if:
InputFirst t < 1000, the number of test cases. In each of the following t lines, 6 integers: -100 <= Ex, Ey <= 100 (coordinates of the center of the ellipse), 0 < a <= 100 (the length of the semi-axis parallel to the x-axis), 0 < b <= 100 (the length of the semi-axis parallel to the y-axis), -100 <= Px, Py <= 100 (the coordinates of P). OutputFor each test, output one number 1, 2 or 3 in a separate line, denoting the appropriate case, as enumerated above. ExampleInput: 4 0 0 5 10 3 8 0 0 5 10 5 0 0 0 5 5 4 4 -10 -10 7 2 -10 -10 Output: 1 1 3 2 ScoringBy solving this problem you score 10 points.
|
||||||||||||||||||
| |||||||||||||||||||