果枫-国峰

2012年9月11日

hdu 1426

摘要: 题意:中文题,此处省。ac代码:View Code #include<iostream>using namespace std;int map[12][12];int k; int foat;struct tree{ int i; int j;}node[90];int check(struct tree n,int p){ int i,j; int x,y; for(i=1;i<=9;i++)//判断行与列是否已经存在p { if(map[n.i][i]==p||map[i][n.j]==p) return 0; ... 阅读全文

posted @ 2012-09-11 21:05 果枫-国峰 阅读(120) 评论(0) 推荐(0) 编辑

hdu 1258

摘要: 题意:中文题,省。ac代码:View Code #include<iostream>#include<string.h>#include<algorithm>using namespace std;int a[15];int use[15];int foat;//判断是否要输出“NONE”int t,n;int k;//use[]数组中使用bool cmp(int a,int b){ return a>b;}void dfs(int s,int step,int k){ if(t==s) { foat=1; for(int i=0;i<k-1;i 阅读全文

posted @ 2012-09-11 21:03 果枫-国峰 阅读(121) 评论(0) 推荐(0) 编辑

导航