manan025 / DS-Algo-Zone

This repository contains codes for various data structures and algorithms in C, C++, Java, Python, C#, Go, JavaScript and Kotlin.
MIT License
25 stars 78 forks source link

Morris Traversal of Binary Trees O(1) Space ( Inorder , Preorder ) #133

Open tm2k23 opened 2 years ago

tm2k23 commented 2 years ago

🚀 Feature

I would like to add morris traversal of binary trees which is done in O(1) space

Have you read the Contribution Guidelines?

Yes

Pitch

=> No recursion => No stacks => O(1) Space

Assignees

(Do not make changes in this section until asked to do so)
C -
C# -
C++ - @tm2k23 Go -
Java -
Javascript -
Kotlin -
Python -

tm2k23 commented 2 years ago

@manan025 please assign C++ to me

manan025 commented 2 years ago

C++ Assigned @tm2k23

tm2k23 commented 2 years ago

@manan025 I forked the repo, in the morning itself, after that I made a PR which was merged, shall I add things in the same cloned repo which was forked in the morning, or do I need to fork again?

manan025 commented 2 years ago

You can create a new branch in that repo and work in that branch. Or you may create new fork repo (any should work) I'd recommend the first one however if you are new to github/ git, you can do the 2nd one.