We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Hii Scott_mankowitz , can you explain me "when not exists(select * from bst where p=o.n) then 'Leaf' else 'Inner' end from bst o order by o.n" , particularly "end from bst" and why do we need to do order by o.n ?
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Binary Tree Nodes
You are viewing a single comment's thread. Return to all comments →
Hii Scott_mankowitz , can you explain me "when not exists(select * from bst where p=o.n) then 'Leaf' else 'Inner' end from bst o order by o.n" , particularly "end from bst" and why do we need to do order by o.n ?