data-structures-and-algorithms

Challenge Title

Extending an Implementation

Whiteboard Process

dequeue()

Approach & Efficiency

Approach:

1- Initialize max_value to negative infinity. 2- Traverse the binary tree recursively. 3- Update max_value with the maximum of the node’s value and the maximum values from the left and right subtrees. 4- Recurse on the left and right children. 5 -Return max_value as the maximum value found. Efficiency:

tests

test_trees_maximum_value.py

Solution

trees.py