F.A.Qs Home ProblemSet Status Ranklist Contest LoginRegister
Notice:1:注册本OJ方式请见https://www.lydsy.com/JudgeOnline/wttl/thread.php?tid=5671 2:请不要在讨论区中发空白主题帖。
大视野在线测评-欢迎您
[ New Thread ]
Problem 3224 >> 我的Splay哪里错了
2730052770 @ 2018-06-09 22:04:41
[ Quote ] [ Edit ] [ Delete ] 1#
你先把文本格式弄得好看一点再说
kjy @ 2018-06-09 22:08:21
[ Quote ] [ Edit ] [ Delete ] 2#
不用了,已解决。
谢谢大犇2730052770 的回复
kjy @ 2018-06-09 22:18:57
[ Quote ] [ Edit ] [ Delete ] 3#
我想问一下splay的
inline void rotate(int ro)
{
int old=tree[ro].fa,oldf=tree[old].fa,whichx=get(ro);
tree[old].ch[whichx]=tree[ro].ch[whichx^1];
tree[tree[old].ch[whichx]].fa=old;
tree[ro].ch[whichx^1]=old;
tree[old].fa=ro;
tree[ro].fa=oldf;
if (oldf)tree[oldf].ch[tree[oldf].ch[1]==old]=ro;
update(old);
update(ro);
}
tree[tree[old].ch[whichx]].fa=old;这句话有什么用
[Top] [Previous Page] [Next Page]

HOME Back