Any better solution other than enum all solutions?

  • 0

    I just put my solution at NQueens to this problem, and removed the code to store the solutions and just counted it.
    And it passed.

    Any other better solution other than enumerate all possible solutions?

  • 0

    As per my knowledge , there is no known formula or recurrence relation and we have to do this by enumerating all solutions

Log in to reply

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.