搜索资源列表
1.10queen
- 要解决N皇后问题,其实就是要解决好怎么放置这n个皇后,每一个皇后与前面的所有皇后不能在同一行、同一列、同一对角线,在这里我们可以以行优先,就是说皇后的行号按顺序递增,只考虑第i个皇后放置在第i行的哪一列,所以在放置第i个皇后的时候,可以从第1列判断起,如果可以放置在第1个位置,则跳到下一行放置下一个皇后。如果不能,则跳到下一列...直到最后一列,如果最后一列也不能放置,则说明此时放置方法出错,则回到上一个皇后向之前放置的下一列重新放置。此即是回溯法的精髓所在。当第n个皇后放置成功后,即得到一个
The-queen
- 实现N个皇后问题,输出所有的排列情况,利用TXT实现输入输出-Realization of N-queens problem, the output of all of the arrangement, the use of input and output TXT achieve
queen
- 局部搜索的方法实现n皇后问题,在较快的时间内找到一个n皇后解。-Local search methods to achieve n queens problem and find a solution in n-queens faster time.
primer
- 一个小的代码:// stack堆栈中保留两个数据(皇后所在的行和列),总共有八个皇后 // 住要特别注意入栈和出栈的顺序。 最后输出计算的结果。-The eight queens puzzle is the problem of placing eight chess queens on an 8×8 chessboard so that no two queens threaten each other. Thus, a solution requires that no
QT_N_queen
- N皇后问题求解工具。能够求解出4—9皇后的所有解,类封装的。图形界面-N Queens problem solving tools. Be able to solve all the solutions of 4-9 Queen of the class package. Graphical interface
n_queens
- 经典N皇后问题:通过编程布局,使任两个皇后都不能处于同一条横行、纵行或斜线上,包含C和C++两种语言代码,其中C语言是以八皇后为特例的。-The classic N-queens problem: let any two queens be not in the same horizontal, vertical or diagonal by using C and C++ language programming, and the C language is based on the eigh
Queen
- n*n的棋盘上放置彼此不受攻击的n个皇后,按国际象棋规则可知:皇后可以攻击同行同列同斜线的棋子-n* n chessboard placed on each other from attack of the n-Queens, according to chess rules we can see: Queen can attack the peer-pawn with the column with a slash
n_queen
- 在n×n格的棋盘上放置彼此不受攻击的n个皇后,按照国际象棋的规则,皇后可以攻击与之处在同一行或同一列或同一斜线上的棋子,求解可以放置的方法种数。-Placed on the n × n chessboard grid attack each other n-queens, in accordance with the rules of chess, the queen can attack in the same row or column, or diagonal pieces of the
suanfa
- 算法设计课程全部代码,包括0-1背包问题,回溯方法解n皇后问题,最大字段和,归并排序等算法,并全部包含人机交互过程-Algorithm design courses all the code, including the 0-1 knapsack problem, backtracking method to solve n-queens problem, the maximum field and, merge sort algorithms, and all include human-co
queen
- 实现n皇后问题,采用回溯方法简单解决。 有详细注释,适合初学者学习。-Achieve n-queens problem using backtracking method is simple to solve. There are detailed notes, suitable for beginners to learn.
n_queens
- Making a MIPS program, which can solve the n-Queens problem? The user will input the number of queens, n > 3, to set on the n x n chess board and the program will determine how to place them in such a way that they are not able to capture one anot
nQueens
- 这是n皇后图形的显示,不仅能显示其寻找过程,还可以将最后的最优解找到-This is the n-queens graphics display, not only to show its finding process, but also the final optimal solution can be found.
the-problem-of-8-queens
- 数据结构实现八(n)皇后问题,c源码+自定义头文件。有注释-the problem of 8 queens,language:C,has comments.
OJ_vcproj
- 主要是经典N皇后的排列放置,同时放置各个皇后之间互相攻击-Mainly placed classic arrangement N Queens, while placing among queens attack each other
N_queen
- 本代码可以实现n皇后的处理,输出总共的方案个数和具体的皇后布局-This code can achieve n-queens of processing, the output total number of programs and specific layout of the Queen
N_QUEENS
- N皇后问题,暴力搜索的解法,效率一般,欢迎交流-N queens problem, solution, violent searching efficiency in general, welcomed the exchange of
NQueens
- nqueens 问题的QS1实现 N-皇后问题的快速局部搜索算法 1分钟可以找到75000皇后的一个解 参考:Rok Sosic and Jun Gu. A Polynomial Time Algorithm for the N-Queens Problem. SIGART Bulletin, 1(3):7-11, 1990.-Fast Local Search Algorithm QS1 nqueens problem realization // // N- Queens pro
NQueen
- N皇后问题,如何能够在 n×n 的国际象棋棋盘上放置n个皇后,使得任何一个皇后都无法直接吃掉其他的皇后-N queens problem, how can we place n queens on an n × n chessboard so that no queen can not directly eat other Queen
NQueen_recursion
- 递归方法解决N皇后问题,任意两个皇后都不能处于同一行、同一列或同一斜线上。输出解法-A recursive method for solving N queens problem, any two queens are not in the same line, the same row or on the same diagonal. Output solution
NQueen_Nonrecursive
- 非递归方法解决N皇后问题,任意两个皇后都不能处于同一行、同一列或同一斜线上。输出解法-A non recursive method for solving N queens problem, any two queens are not in the same line, the same row or on the same diagonal. Output solution