上一页 1 ··· 17 18 19 20 21 22 23 24 25 ··· 37 下一页
摘要: Given n nodes in a graph labeled from 1 to n. There is no edges in the graph at beginning. You need to support the following method: 1. connect(a, b), 阅读全文
posted @ 2017-11-12 02:14 Review->Improve 阅读(587) 评论(0) 推荐(0) 编辑
摘要: Find the number Weak Connected Component in the directed graph. Each node in the graph contains a label and a list of its neighbors. (a weak connected 阅读全文
posted @ 2017-11-12 01:50 Review->Improve 阅读(603) 评论(0) 推荐(0) 编辑
摘要: Find the number connected component in the undirected graph. Each node in the graph contains a label and a list of its neighbors. (a connected compone 阅读全文
posted @ 2017-11-11 12:24 Review->Improve 阅读(1694) 评论(0) 推荐(0) 编辑
摘要: Six degrees of separation is the theory that everyone and everything is six or fewer steps away, by way of introduction, from any other person in the 阅读全文
posted @ 2017-11-11 09:53 Review->Improve 阅读(530) 评论(0) 推荐(0) 编辑
摘要: Deep clone an undirected graph. Each node in the graph contains a label and a list of its neighbors. How we serialize an undirected graph: Nodes are l 阅读全文
posted @ 2017-11-11 09:32 Review->Improve 阅读(411) 评论(0) 推荐(0) 编辑
摘要: Given n nodes labeled from 0 to n - 1 and a list of undirected edges (each edge is a pair of nodes), write a function to check whether these edges mak 阅读全文
posted @ 2017-11-10 13:06 Review->Improve 阅读(530) 评论(0) 推荐(0) 编辑
摘要: Given a undirected graph, a node and a target, return the nearest node to given node which value of it is target, return NULL if you can't find. There 阅读全文
posted @ 2017-11-10 11:14 Review->Improve 阅读(824) 评论(0) 推荐(0) 编辑
摘要: Given an integer array, heapify it into a min-heap array. For a heap array A, A[0] is the root of heap, and for each A[i], A[i * 2 + 1] is the left ch 阅读全文
posted @ 2017-11-08 14:43 Review->Improve 阅读(388) 评论(0) 推荐(0) 编辑
摘要: There are a total of n courses you have to take, labeled from 0 to n - 1.Some courses may have prerequisites, for example to take course 0 you have to 阅读全文
posted @ 2017-11-08 02:09 Review->Improve 阅读(407) 评论(0) 推荐(0) 编辑
摘要: There are a total of n courses you have to take, labeled from 0 to n - 1. Some courses may have prerequisites, for example to take course 0 you have t 阅读全文
posted @ 2017-11-07 14:47 Review->Improve 阅读(436) 评论(0) 推荐(0) 编辑
上一页 1 ··· 17 18 19 20 21 22 23 24 25 ··· 37 下一页