(function(){ window.OpenPopKa = true;}())

Write a recursive function to set the value for each node in a binary tree to be its depth. Assume that nodes store integer values. On the initial call to BTsetdepth, "depth" is 0.

[editor.getValue()]
if (guess[0] != initEditor) { console.log(guess[0]); window.codeValue = guess[0]; window.progexType= "BTRecurTutor"; window.summexName= "BTsetdepthPROG"; } else { return ""; }

For this exercise, you need to do a traversal that visits each node of the tree, and sets the depth to the value that has been passed to it. No information needs to be returned.

However, the depth must be incremented by 1 on each recursive call.