摘要: 1 #include<stdio.h> 2 3 int n,l; 4 char s[100]; 5 6 int dfs(int cur) 7 { 8 int i,j,ok,equal,k; 9 if(cur==n)10 {11 for(i=0;i<n;i++)12 printf("%c",'A'+s[i]);13 printf("\n");14 return 0;15 }16 for(i=0;i<l;i++)17 {18 s[cur]=i;19 ... 阅读全文
posted @ 2013-04-03 22:25 萧凡客 阅读(278) 评论(0) 推荐(0) 编辑
摘要: 1 #include<stdio.h> 2 #include<string.h> 3 #include<queue> 4 using namespace std; 5 6 const int max=100; 7 int c[3]; 8 int w; 9 int vis[max][max];10 int m;11 typedef struct 12 {13 int v[3];14 int deep;15 //ruct node *fa;16 //t a;17 //t b;18 }node;19 20 21 int bfs()22 {23 in... 阅读全文
posted @ 2013-04-03 17:53 萧凡客 阅读(173) 评论(0) 推荐(0) 编辑