How can i go about implemting 8/4 queens problem?Should i use DFS/BFS,I think DFs will be better. Can any one give some pseudocode/guidlines?
Use a stack and backtracking, easiest way is via recursion.
See these other SO posts:
Dumb 8 Queens problem in C++
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With