2026-rff_mp/MusinAA/task2/strategyObjects/pathFindingStrategy.py

12 lines
695 B
Python
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

from abc import ABC, abstractmethod
from task2.mazeObjects.maze import Maze
from task2.mazeObjects.cell import Cell
class PathFindingStrategy(ABC):
"""Интерфейс PathFindingStrategy с методом findPath(maze, start, exit),
возвращающим список клеток пути (от старта до выхода включительно) или пустой список, если пути нет."""
@abstractmethod
def findPath(self, maze: Maze, start: Cell, exit: Cell):
"""Возвращает список клеток пути от старта до выхода включительно. Пути нет - пустой список."""