凉 (比赛链接)[https://www.nowcoder.com/acm/contest/177#question] T1 (题目链接)[https://www.nowcoder.com/acm/contest/177/A] 首先考虑二维前缀和 [l1, r1], [l2, r2]的解 即ans([0, r1], [0, r2]) - ans([0, l1 - 1], [0, r2]) - ans([0, l2 - 1], [0, r1]) + ans([0, l1 - 1], [0, l2…