摘要:
130. Surrounded Regions BFS: 把所有边界上的O先换成A(标记),再深度遍历周围的点。 最后把O换成X(表示不符合要求),所有的A换回O class Solution { public void solve(char[][] board) { if(board.length 阅读全文
摘要:
382. Linked List Random Node class Solution { ListNode node; Random random; /** @param head The linked list's head. Note that the head is guaranteed t 阅读全文