摘要:
搜索*号能到的位置,置为#,然后输出整个输入的迷宫。#include<cstdio>#include<cstring>#include<cstdlib>char a[35][85];char b[100];const int dx[] = { 1, -1, 0, 0};const int dy[] = { 0, 0, -1, 1};void dfs( int x, int y){ for( int d = 0; d < 4; d ++) { int nx = x + dx[d]; int ny = y + dy[d]; if( a[nx][... 阅读全文
posted @ 2011-12-14 23:44
找回失去的
阅读(227)
评论(0)
推荐(0)
摘要:
http://acm.csu.edu.cn/OnlineJudge/problem.php?id=1226这也是月赛题,不知道当时怎么想的,居然没有写这道题...两个字符串中的字符有对应的关系,一对多和多对一都不行...#include<cstdio>#include<cstring>#include<cstdlib>#define SIZE 300char s1[SIZE], s2[SIZE], s3[SIZE], s4[SIZE], a[SIZE], b[SIZE], c[SIZE], d[SIZE];bool f1[100], f2[100];int 阅读全文
posted @ 2011-12-14 13:37
找回失去的
阅读(250)
评论(0)
推荐(0)
浙公网安备 33010602011771号