Sun Yat-sen University Programming Contest

From EOJ Wiki
Revision as of 10:34, 21 April 2019 by Xiejiadong (talk | contribs) (Created page with "== Problem A == Solved by Kilo_5723. 03:48:17 (-1) == Problem B == Solved by Kilo_5723. 00:17:23 (-2) == Problem C == Unsolved. == Problem D == Solved by Xiejiadong. 01...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Problem A

Solved by Kilo_5723. 03:48:17 (-1)

Problem B

Solved by Kilo_5723. 00:17:23 (-2)

Problem C

Unsolved.

Problem D

Solved by Xiejiadong. 01:49:36 (-5)

题意:给出一些矩形覆盖平面,询问一个矩形区域,问是否已经被覆盖。

题解:二维平面差分。对于矩形\((a,b,c,d)\),在位置\((a,b)\; +1\)、\((a,d+1)\; -1\)、\((c+1,b)\; -1\)、\((c+1,d+1)\; +1\),进行一起前缀和,就能得到所有矩阵位置被覆盖的次数。

对于所有满足\(\ge 1\)的位置,即已经被覆盖的位置,改成\(1\),其余为\(0\)

Problem E

Unsolved.

Problem F

Unsolved.

Problem G

Unsolved.

Problem H

Unsolved.

Problem I

Unsolved.

Problem J

Unsolved.

Problem K

Unsolved.