Home > Mobile >  How to properly delete a node from an AVL Binary Tree in the C language
How to properly delete a node from an AVL Binary Tree in the C language

Time:01-04

I am trying to encode an AVL binary tree in the C language. My implementation uses an over-arching struct to keep track of the length of the binary tree (i.e. number of nodes), as well as a pointer t the root, and the init status of the data structure. I have been able to encode an implementation correctly balances the tree at every insertion. However, I am having problems balancing the tree when I delete a node. I am trying to use an example listed on GeeksforGeeks (Graph of tree.

Immediately, you can tell that the heights don't sense.

  • Related