Open nsuthison opened 4 years ago
Since Java uses pass by value even if the object is a reference type, so when you set node = null here is gonna effect only in the local scope.
Ps. Thank you for your course, it really helps me understanding data structure more and also more efficient in recursive function which I lack :)
Since Java uses pass by value even if the object is a reference type, so when you set node = null here is gonna effect only in the local scope.