Problem E
Kitty Pokey
You put your whiskers in, you put your whiskers out.
You put your whiskers in, and you shake them all about.
You do the kitty pokey, and you turn yourself around.
That’s what it’s all about.
Cats use their whiskers to explore the space around them, even in total darkness. You will be presented with the coordinates of the whisker tips, ear tips, and chin (relative to the kitty’s nose) and the dimensions of a rectangular box opening. Can the kitty fit her head (whiskers, ears, and chin) through the opening if it approaches without rotating its head and the box is lying flat on its side?
Input
The first line contains a positive integer, $w$ ($w <= 25$), which is the number of whiskers. Following the first line will be $w+3$ lines of two real numbers each representing the $x$ and $y$ coordinates of the whisker tips, the ear tips, and the chin, using the nose as the origin ($0.0$", $0.0$"). All coordinates will be less than $20.0$" in absolute value, which is fairly large, but this is so that we might consider a Siberian tiger. One final line contains the width and height of the box opening, each of which will be less than or equal to $36$". Assume no part of the kitty’s head extends beyond the tips listed.
Output
Print the message “Kitty fits!” If the kitty can get her head in the box, or “Sorry kitty!” if she can’t.
| Sample Input 1 | Sample Output 1 |
|---|---|
6 -1.85 1.25 2.15 1.55 0.00 -1.10 -2.55 0.50 2.35 0.70 -2.20 -0.50 2.25 -0.30 -2.50 -1.50 2.00 -1.20 5.50 3.70 |
Kitty fits! |
| Sample Input 2 | Sample Output 2 |
|---|---|
6 -1.85 1.25 2.15 1.55 0.00 -1.10 -2.55 0.50 2.35 0.70 -2.20 -0.50 2.25 -0.30 -2.50 -1.50 2.00 -1.20 4.80 3.50 |
Sorry kitty! |
