Two elements of a binary search tree (BST) are swapped by mistake. Recover the tree without changing its structure. Note:A solution using O(n) space is pretty straight forward. Could you devise a constant space solution? confused what "{1,#,2,3}"
"--出自"关于 Jeff Dean 的事实" 其实,"关于 Jeff Dean 的事实"这个G+ 帖中描述的并非是真实的.不过有人大费周折为他建立了一个类似于"关于 Chuck Norris 的事实"这样的网站,这倒是件不同寻常的事. 这是因为 Jeff Dean 是一位软件工程师,而软件工程师们通常是不会像武术界的战神 Chuck Norris 那样的. 一方面,他们不是独行侠,软件开发从本质上来讲是一个协作过程. 另一方面,他们也