/TreeTraverser

Primary LanguageJavaMIT LicenseMIT

Purpose

Write Android app to traverse a binary tree. Do this as a learning exercise.

References

https://en.wikipedia.org/wiki/Tree_traversal

tree_traverser Python

Practice traversing a binary tree using recursive depth first search.
https://github.com/beepscore/tree_traverser

Results

Background

Problem statement

Write a method to check if a tree contains a node with a given value.

Assumptions

Values are not necessarily sorted.

Plan

Depth first

Implement depth first recursive traverse.

Breadth first

Alternative method. Implement breadth first traverse. Use stack or queue.

Tests

See tests for implemented behavior.