※ 引述《CorruptAngel (微笑面具)》之銘言:
: We did so too:(
: but we still wrote a greedy search and got WA.
: ※ 引述《denehs (DE)》之銘言:
: : I create a 1-D array to record when is the next time the DVD will be
: : requested,and if it won't appear again,give it a value 110 (because the
: : max length is 100),and got WA....><..
: : We though that greedy was an incorrect algorithm,so didn't debug.......
: : (chinese typing crashed...XD)
這題想不出來的話可以用 mincost maxflow, 有流量下界的那種來解
worst case: 流量 10, node 約 10000, edge 約 1000000
要做 10 次有負邊最短路徑, 而這種圖非常特別, 或許有什麼很快的求法
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.112.30.20