Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Morris In-Order Traversal algorithm #980

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

BEaANIKET
Copy link

Summary:

This PR adds a new C++ implementation of the Morris In-Order Traversal algorithm for binary search trees. This algorithm allows in-order traversal with O(1) space complexity.

Changes:

  • Added morrisTraversal.cpp with:
    • Problem statement
    • Detailed comments on the code
    • Time and space complexity analysis

Reason:

Morris Traversal is useful for applications that require in-order traversal without additional space overhead. This implementation can be beneficial for educational purposes and optimizing resource usage.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant