Lines Matching refs:lchild
95 int lchild[N + 1], rchild[N + 257], parent[N + 1];
156 * For i = 0 to N - 1, rchild[i] and lchild[i] will be the right and left
192 sp->rchild[r] = sp->lchild[r] = NIL;
204 if (sp->lchild[p] != NIL)
205 p = sp->lchild[p];
207 sp->lchild[p] = r;
223 sp->lchild[r] = sp->lchild[p];
225 sp->parent[sp->lchild[p]] = r;
230 sp->lchild[sp->parent[p]] = r;
242 q = sp->lchild[p];
243 else if (sp->lchild[p] == NIL)
246 q = sp->lchild[p];
251 sp->rchild[sp->parent[q]] = sp->lchild[q];
252 sp->parent[sp->lchild[q]] = sp->parent[q];
253 sp->lchild[q] = sp->lchild[p];
254 sp->parent[sp->lchild[p]] = q;
263 sp->lchild[sp->parent[p]] = q;