From df29d66f1572b97f40e2504a1db2fd9709575dc3 Mon Sep 17 00:00:00 2001 From: konnovaea Date: Mon, 18 May 2026 20:55:51 +0300 Subject: [PATCH] =?UTF-8?q?=D1=83=D0=B4=D0=B0=D0=BB=D0=B5=D0=BD=D0=BE=20?= =?UTF-8?q?=D1=82=D0=B5=D1=81=D1=82=D0=B8=D1=80=D0=BE=D0=B2=D0=B0=D0=BD?= =?UTF-8?q?=D0=B8=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- konnovaea/maze_solver.py | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/konnovaea/maze_solver.py b/konnovaea/maze_solver.py index d6195b9..8fbc904 100644 --- a/konnovaea/maze_solver.py +++ b/konnovaea/maze_solver.py @@ -178,19 +178,3 @@ class MazeSolver: return SearchStats(path, (end_time - start_time) * 1000, visited) -if __name__ == "__main__": - builder = TextFileMazeBuilder() - maze = builder.build_from_file("maze1.txt") - - print(f"Лабиринт: {maze.width}x{maze.height}") - print(f"Старт: {maze.start}") - print(f"Выход: {maze.exit}") - print() - - solver = MazeSolver(maze) - - for name, strategy in [("BFS", BFSStrategy()), ("DFS", DFSStrategy()), ("A*", AStarStrategy())]: - solver.set_strategy(strategy) - stats = solver.solve() - print(f"{name}: путь={stats.path_length}, время={stats.time_ms:.3f}мс, посещено={stats.visited_count}") -