DSA-Bootcamp-Java
DSA-Bootcamp-Java copied to clipboard
Update AVL.java
Height Initialization: The height is initialized in the Node constructor to avoid null references. Duplicate Handling: The insert method now checks for duplicates and does nothing if the value already exists. Height Calculation: The height is updated correctly during rotations.