MCPcopy Create free account
hub / github.com/TheAlgorithms/JavaScript /

Class

Backtracking/KnightTour.js:3–3  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1// Wikipedia: https://en.wikipedia.org/wiki/Knight%27s_tour
2
3class OpenKnightTour {
4 constructor(size) {
5 // Constructor to initialize the chessboard and size
6 this.board = new Array(size).fill(0).map(() => new Array(size).fill(0))

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected