0

Hi everyone,

I am a year 1 student who is having a course of data strcutures.

My assignment 's deadlin is by tomorrow. the assignment is avl tree.

I have completed the followings.

```
struct AVLnode_s {
char element;
int height;
struct AVLnode *left;
struct AVLnode *right;
};
typedef struct AVLnode_s AVLnode;
AVLnode *doubleRotateWithLeft(AVLnode *k3) {
AVLnode *k1, *k2;
k1 = k3->left; k2 = k1->right;
k1->right = k2->left;
k3->left = k2->right;
k2->left = k1;
k2->right = k3;
k1->height = max(height(k1->left), height(k1->right)) + 1;
k3->height = max(height(k3->left), height(k3->right)) + 1;
k2->height = max(height(k2->left), height(k2->right)) + 1;
return k2;
}
```

.........

However, I have no idea on how to find the 'height' of the tree.

Would anybody kindly help? I really need the source codes urgently as without it, the whole program would not be evaluated by my tutors. I am going to fail definitely.....Please please.....

Thank you very much