From 1dad24f9897bf2d11ebc29b95214658316e721ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torma=20Krist=C3=B3f?= Date: Fri, 2 Oct 2020 01:45:05 +0200 Subject: [PATCH] range should start at one --- app.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app.py b/app.py index 33547bd..5be0578 100644 --- a/app.py +++ b/app.py @@ -8,7 +8,7 @@ def read_graph(graph_file: str = 'valos_halozat_other_dataset.txt') -> dict: vertices = int(f.readline()) edges = int(f.readline()) result_graph: ig.Graph = ig.Graph(vertices) - for _ in range(edges): + for _ in range(1, edges): line = f.readline().split('\t') result_graph.add_edge(int(line[0]), int(line[1])) return {"graph": result_graph, "edges": edges, "vertices": vertices}