-
Notifications
You must be signed in to change notification settings - Fork 177
Open
Description
If we switch the order of these directions, it will not pass the Leetcode test any longer.
Lines 83 to 84 in bc10ad9
char[] dstr = {'u', 'd', 'l', 'r'}; | |
int[][] dirs = {{-1, 0}, {1, 0}, {0, -1}, {0, 1}}; |
While change the order:
char[] dstr = {'d', 'u', 'l', 'r'};
int[][] dirs = {{1, 0}, {-1, 0}, {0, -1}, {0, 1}};
test case failed: [[0,0,0,0,0],[1,1,0,0,1],[0,0,0,0,0],[0,1,0,0,1],[0,1,0,0,0]]
[4,3]
[0,1]
Output "dldul"
Expected "lul"
Metadata
Metadata
Assignees
Labels
No labels