Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- node* find(node* start, int key) {
- if (start == NULL) {
- return NULL;
- }
- if (key == start->key) {
- return start;
- }
- else {
- if (key > start->key) {
- return find(start->r, key);
- }
- if (key < start->key) {
- return find(start->l, key);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment