Skip to content

sangamsahai/Recursive-Backtracking---N-Queens-problem---Java-Implementation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

This is an implementation of the famous N Queens problem in Java. This uses the concept of Recursive Backtracking.

This class uses a helper function place() which returns true if the Queen can be placed in the given co ordinates.

positionInRow - This array will hold the column value of placed Queens where the index of the cell will indicate the row value.

You can change the value of gridSize in the main() function and get the placement co ordinates for any given grid size.

About

Recursive Backtracking - N Queens problem - Java Implementation

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages