input: Write a function to check if a binary tree is a subtree of another binary tree. If it is a subtree return True else return False. If both trees are empty return True.
  
  def isSubTree(T, S):
      
      if S is None: 
          return True
    
      if T is None: 
          return False
    
      if areIdentical(T, S): 
          return True
    
      return isSubTree(T.left, S) or isSubTree(T.right, S) 
    
    
  def areIdentical(T, S): 
        
      if T is None and S is None: 
          return True
    
      if T is None or S is None: 
          return False
    
      return (T.data == S.data and areIdentical(T.left, S.left)and
          areIdentical(T.right, S.right))
  
  # Testing cases
  assert isSubTree(Node(1), Node(1)) == True
  assert isSubTree(None, None) == True
  assert isSubTree(Node(1), None) == True
  assert isSubTree(None, Node(1)) == False
  assert isSubTree(Node(1), Node(2)) == False
  assert isSubTree(Node(1, Node(2), Node(3)), Node(1, Node(2), Node(3))) == True
  assert isSubTree(Node(1, Node(2), Node(3)), Node(2)) == True
  assert isSubTree(Node(1, Node(2), Node(3)), Node(4)) == False
  assert isSubTree(Node(1, Node(2, Node(4), Node(5)), Node(3)), Node(2, Node(4), Node(5))) == True
output: def isSubTree(T, S):
      
      if S is None: 
          return True
    
      if T is None: 
          return False
    
      if areIdentical(T, S): 
          return True
    
      return isSubTree(T.left, S) or isSubTree(T.right, S) 
    
    
  def areIdentical(T, S): 
        
      if T is None and S is None: 
          return True
    
      if T is None or S is None: 
          return False
    
      return (T.data == S.data and areIdentical(T.left, S.left)and
          areIdentical(T.right, S.right))