摘要: #include#include#define LOCALusing namespace std;int m[10][10]={0};int num=0;int check(int row,int column)//检查当前状态下能否放置{ int i,j; if(row==1) return 1; for(i=1;i=1&&j>=1)对左上到当前点进行检查 { if(m[i][j]==1) return 0; i--;j--; } i=row-1; j=column+1; while(i>=1&&j<=8)//对当前点到又上进行检查 { if 阅读全文
posted @ 2013-12-18 17:50 ACalvin 阅读(211) 评论(0) 推荐(0) 编辑