Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

在题目矩阵中的路径(12)的算法描述上好像有点不对 #139

Open
Louis-udm opened this issue Jul 20, 2022 · 2 comments
Open

Comments

@Louis-udm
Copy link

算法应该是在匹配到第一个字符后,才真正开始递归dfs,而在匹配不到第一个字符的时候,是双循环继续在矩阵中查找第一个字符,这个时候并没从矩阵当前字符的4个方向去走。当然匹配到一半失败的,也会在双循环中继续往下重新找第一个字符。我的意思,寻找第一个匹配字符失败的时候,并不是朝4个方向走。

@Shirman
Copy link

Shirman commented Jul 20, 2022 via email

@Teemo100
Copy link

Teemo100 commented Jul 20, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants