Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
O(n*logn)可解 枚举height+二分上下界O(n*logn)可解 从大到小枚举height,然后二分上下界,分别统计该组内属于A,B的个数(a,b)(可预处理),然后拿a*b*w (w=该组height-该组上下界height最大值)。如果该height已被之前统计过,跳过即可 欢迎大家探讨~ Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator