Last active
July 13, 2019 10:10
-
-
Save parvezmrobin/f7a63a11d5c3ec7d370bea0250104f1c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function* inOrder (node) { | |
| if(node.left){ | |
| yield *inOrder(node.left); | |
| } | |
| yield node.value; | |
| if(node.right){ | |
| yield *inOrder(node.right); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment