Define a procedure called make-avl-tree, C/C++ Programming

This question deals with AVL trees. The representation to be used is similar to the bank account object discussed in class.

(a) Define a procedure called make-avl-tree which makes an AVL tree with no nodes. The procedure returns an AVL tree object.

(b) Write a procedure called (insert n t). This procedure has 2 arguments: n is the value being inserted, t is the AVL tree.

(c) Write a procedure called (lookup n t). This procedure has 2 arguments: n is the value being looked up, t is the AVL tree.

(d) Write a procedure called (delete n t). This procedure has 2 arguments: n is the node to be deleted, t is the AVL tree.

(e) Write a procedure called (print t). This procedure prints the AVL tree passed in t in inorder traversal form.

 

Posted Date: 3/25/2013 1:08:57 AM | Location : United States







Related Discussions:- Define a procedure called make-avl-tree, Assignment Help, Ask Question on Define a procedure called make-avl-tree, Get Answer, Expert's Help, Define a procedure called make-avl-tree Discussions

Write discussion on Define a procedure called make-avl-tree
Your posts are moderated
Related Questions
What is the role of && operator in a program code? - && is also referred to as AND operator. - When this operator is used, all conditions specified should be TRUE before nex

C Program for SELECT THE CHAR WHICH U WANT #include stdio.h> #include conio.h> void main() {             void substr(char[], int *, int *);           int a,b

make a marksheet of 2 student with 5 subject

Inline functions, C++ provides inline functions to help reduce function_call overhead especially for small functions. The qualifier inline before function's return type in the f

C Program for FUNCTION OF DIVIDER int gcd(int , int); void main() {           int m=0,n=0,k=0;           clrscr();           printf("ENTER THE FIRST DIGIT: ");

Write a simple generic version of method isEqualTo that compares its two arguments with the equals method and returns true if they are equal and false otherwise. Use this generic m

What is meant by open addressing? Explain various collision resolution techniques with example

algorithem of compound interest


Write a program to find the area under the curve y = f(x) between x = a and x = b, integrate y = f(x) between the limits of a and b. The area under a curve between two points can b