We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8aaf33a commit 9fde3c5Copy full SHA for 9fde3c5
src/main/java/com/thealgorithms/backtracking/WordSearch.java
@@ -35,19 +35,6 @@
35
* - Stack space for the recursive DFS function, where L is the maximum depth of recursion (length of the word).
36
*/
37
public class WordSearch {
38
- private char[][] board;
39
- private String word;
40
-
41
- /**
42
- * Checks if the given (x, y) coordinates are valid positions in the board.
43
- *
44
- * @param x The row index.
45
- * @param y The column index.
46
- * @return True if the coordinates are within the bounds of the board; false otherwise.
47
- */
48
- private boolean isValid(int x, int y) {
49
- return x >= 0 && x < board.length && y >= 0 && y < board[0].length;
50
- }
51
52
/**
53
* Performs Depth First Search (DFS) from the cell (x, y)
0 commit comments