「ceoi 2009」harbingers
link。朴素 dp 大约就是 $f_x=f_y+v_x\times(d_x-d_y)+s_x$,$y$ 是 $x$ 的祖先。这个式子可以斜率优化,在以 $d_y$ 为横坐标,$f_y$ 为纵坐...
In mathematics you don't understand things, you just get used to them.
In mathematics you don't understand things, you just get used to them.