【2019.10.8】

T1. Phalanx

Meaning of the questions: n * m of the square, the i-th row j column value Xij, to the left and right corners of a rectangle given a few asked SUM / MAX / MIN?

Solution: I was playing prefix and seek SUM, MIN and MAX but encountered directly kneeling enumeration fight, violence took 40 minutes.

Code:

 

Guess you like

Origin www.cnblogs.com/jian-song/p/11634925.html