摘要:
Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent a number.An example is the root-to-leaf path 1->2->3 which represents the number 123.Find the total sum of all root-to-leaf numbers.For example, 1 / \ 2 3The root-to-leaf path 1->2 represents the num 阅读全文
posted @ 2013-08-11 15:26
冰点猎手
阅读(175)
评论(0)
推荐(0)
摘要:
Given a 2D board containing 'X' and 'O', capture all regions surrounded by 'X'.A region is captured by flipping all 'O's into 'X's in that surrounded region .For example,X X X XX O O XX X O XX O X XAfter running your function, the board should be:X X X XX X X 阅读全文
posted @ 2013-08-11 15:11
冰点猎手
阅读(173)
评论(0)
推荐(0)