package
0.0.0-20230710210237-5ce2504b62fa
Repository: https://github.com/shomali11/go-interview.git
Documentation: pkg.go.dev

# README

Description

Check if a binary tree is balanced. A balanced tree is a tree where every leaf is “not more than a certain distance” away from the root than any other leaf.

Example 1:

Input:

     4
   /   \
  2     7
 / \   / \
1   3 6   9

Output:
true

Example 2:

Input:

     4
   /  
  2   
 / \  
1   3 

Output:
false

# Functions

IsBalanced checks if a binary tree is balanced.