From 17289730499dc15dbf8d5d311062e5266317b37e Mon Sep 17 00:00:00 2001 From: Anatoliy Vasilev <113770358+TreshMom@users.noreply.github.com> Date: Wed, 17 Apr 2024 22:21:19 +0300 Subject: [PATCH] Update task3.py --- project/task3.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/project/task3.py b/project/task3.py index c95ba05ce..33b1afd99 100644 --- a/project/task3.py +++ b/project/task3.py @@ -77,6 +77,7 @@ def is_empty(self) -> bool: def intersect_automata( automaton1: FiniteAutomaton, automaton2: FiniteAutomaton ) -> FiniteAutomaton: + commaon_keys = automaton1.func_to_steps.keys() & automaton2.func_to_steps.keys() finatie_automaton = FiniteAutomaton() finatie_automaton.func_to_steps = {} @@ -100,7 +101,6 @@ def intersect_automata( return finatie_automaton - def paths_ends( graph: MultiDiGraph, start_nodes: set[int], final_nodes: set[int], regex: str ) -> list[tuple[int, int]]: @@ -127,5 +127,4 @@ def convert_to_node(i): if m[st, fi] != 0: res.append((convert_to_node(st), convert_to_node(fi))) - return res