diff --git a/dynamic_programming/regex_match.py b/dynamic_programming/regex_match.py index ac0a3bd2a..200a88283 100644 --- a/dynamic_programming/regex_match.py +++ b/dynamic_programming/regex_match.py @@ -74,7 +74,6 @@ def dp_match(text: str, pattern: str) -> bool: dp = [[False for _ in range(n + 1)] for _ in range(m + 1)] dp[0][0] = True - for j in range(1, n + 1): dp[0][j] = pattern[j - 1] == "*" and dp[0][j - 2]