瀏覽代碼
Update dfs.py
pull/31/head
NANCY ANAND
4 年前
committed by
GitHub
沒有發現已知的金鑰在資料庫的簽署中
GPG 金鑰 ID: 4AEE18F83AFDEB23
共有
1 個檔案被更改,包括
1 行新增 和
1 行删除
-
dfs.py
|
|
@ -12,7 +12,7 @@ class Graph: |
|
|
|
# default dictionary to store graph |
|
|
|
self.graph = defaultdict(list) |
|
|
|
|
|
|
|
# function to add an edge to graph |
|
|
|
|
|
|
|
def addEdge(self, u, v): |
|
|
|
self.graph[u].append(v) |
|
|
|
|
|
|
|