sTree *find_node(key_type e, sTree *t) { /* Returns a pointer to the node in the sTree with the given value. */ /* Returns NULL if there is no such node. */ /* Does not change the sTree. To guarantee logarithmic behavior, */ /* the node found here should be splayed to the root. */ T lsize; / if ((value < 0) || (value >= node_value(t))) return NULL; for
| 240 | // } |
| 241 | //} |
| 242 | void free_sTree(sTree* t) |
| 243 | { |
| 244 | if(t==NULL) return; |
| 245 | free_sTree(t->right); |
| 246 | free_sTree(t->left); |
| 247 | free_node(t); |
| 248 | } |
| 249 | void print_sTree(sTree * t, int d) { |
| 250 | //printf("%p\n",t); |
| 251 | int i; |
no test coverage detected