Disgusting Japanese Man

??? A 37-year-old Japanese man has been arrested after placing 10,000 calls to directory assistance. He did not need to get phone numbers, rather, he called because he enjoyed having the operators chide him.


??? He reportedly told police that he was lonely and grew to enjoy annoying the operators.


??? "I would go into ecstasy when a lady scolded me," he was quoted as saying by Jiji Press.


??? Telephone operators - who in Japan are almost always women - nicknamed him the "don't-hang-up-man".


??? His calls usually came late and sometimes exceeded 200 times a night, Jiji Press said.

Japanese Writing


DescriptionnnMichael had visited ACM ICPC World Finals 2007 in Tokyo, Japan and became fascinated with Japanese writing. He decided to study hieroglyphs, but in order to check his knowledge he needs a piece of software that can verify correctness of his writing. This program takes a description of a correct shape of the hieroglyph, several Michael’s attempts to write it, and judges each attempt as correct or incorrect.nnIn this problem hieroglyphs are represented as a collection of strokes, each stroke being a straight line on a Cartesian plane. The order of strokes is irrelevant for the hieroglyph shape, but the direction of each stroke is relevant. There are eight relevant directions: straight right, upper-right, straight up, upper-left, straight left, lower-left, straight down, and lower-right.nnTwo writings are considered to represent the same shape if one-to-one correspondence can be established between the strokes and all the endpoints of the strokes, so that direction of strokes and relative positions of pairs of points are preserved. Preservation of relative positions is important for any pair of points, even if they are not connected with a stroke. However, relative positions are important only with respect to eight relevant directions described above.nnFor example, here is a hieroglyph similar to Latin letter A with 5 endpoints connected with 3 strokes and several other correct writings of the same shape:nnnNote, that intersections of strokes are not relevant. Here are several incorrect writings of the same shape:nnnThese writings are not correct for the following reasons:nnWriting 5 has an extra point, so one-to-one correspondence between endpoints cannot be established.nIn writing 6 point d is straight up from point a but it should be to the upper-right of it.nIn writing 7 stroke d − e goes in the wrong direction.nIn writing 8 point c is lower-right from point a but it should be straight to the right of it.nWriting 9 has an extra a − d stroke, so one-to-one correspondence between strokes cannot be established.nInputnnThe first line of the input file contains a single integer n (2 ≤ n ≤ 20) — the number of writings in the input file. It is followed by descriptions of n writings.nnEach writing starts with a line with a single integer number mi (1 ≤ mi ≤ 100) — the number of strokes in i-th writing. It is followed by mi lines that describe strokes for i-th writing. Each stroke is represented by a line with four integer numbers xaij, yaij, xbij, and ybij (−1000 ≤ xaij, yaij, xbij, ybij ≤ 1000) — coordinates of endpoints. xaij, yaij are coordinates of the beginning of j-th stroke and xbij, ybij are coordinates of the end of j-th stroke. The beginning and the end of the stroke are distinct points. Any two endpoints are connected by at most one stroke.nnOutputnnCompare the shapes of writings from 2nd to n-th with the shape of the first writing and write to the output file n − 1 lines with the result of each comparison of a single line. Write CORRECT if the corresponding writing represents the same shape as the first one or INCORRECT otherwise.nnSample Inputnn9n3n0 0 10 20n10 20 20 0n5 10 15 10n3n0 0 10 20n10 20 20 0n2 10 13 10n3n0 0 10 15n10 15 20 0n5 10 15 10n3n8 10 12 10n0 0 10 20n10 20 14 0n3n0 0 8 20n12 20 20 0n5 10 15 10n3n0 0 10 20n10 20 20 0n0 10 15 10n3n0 0 10 20n10 20 20 0n15 10 5 10n3n2 4 10 20n10 20 20 0n5 10 15 10n4n0 0 10 20n0 0 5 10n10 20 20 0n5 10 15 10nSample OutputnnCORRECTnCORRECTnCORRECTnINCORRECTnINCORRECTnINCORRECTnINCORRECTnINCORRECT


  • 广告
  • 抄袭
  • 版权
  • 政治
  • 色情
  • 无意义
  • 其他