博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
传说中的滑雪,巨丑勿拍(poj1088/tyvj1004)
阅读量:4595 次
发布时间:2019-06-09

本文共 491 字,大约阅读时间需要 1 分钟。

不大会写记忆化,各种不蛋定……

const	wx:array[1..4]of longint=(1,-1,0,0);	wy:array[1..4]of longint=(0,0,1,-1);var	ans,i,j,r,c:longint;	a,f:array[0..100,0..100]of longint;	visit:array[0..100,0..100]of boolean;procedure dfs(x,y:longint);var	nx,ny,i:longint;begin	visit[x,y]:=true;	for i:=1 to 4 do	begin		nx:=x+wx[i];		ny:=y+wy[i];		if (nx>=1)and(ny>=1)and(nx<=c)and(ny<=r)and(a[nx,ny]
ans then ans:=f[j,i]; writeln(ans);end.

转载于:https://www.cnblogs.com/lexluthor/archive/2011/10/14/2211220.html

你可能感兴趣的文章
编码风格
查看>>
Linux的ls命令在Windows中的应用
查看>>
4.Spring注解+SpringMVC注解+MyBatis注解(动态sql)
查看>>
算法导论 CLRS 24.1-5 解答
查看>>
接了个私单,结果对方有部分尾款迟迟不付,还好有留了个后门
查看>>
keep the bar green to keep the code clean——Junit详解(二)
查看>>
system表空间空间解决(ORA-00604 ORA-01653 ORA-02002)
查看>>
【原创】敏捷软件产品/项目开发管理流程(一)
查看>>
Node.js中的express框架,修改内容后自动更新(免重启),express热更新
查看>>
团队每日冲刺04
查看>>
oracle中的decode的使用
查看>>
PHP生成中文验证码并检测对错实例
查看>>
数据库经典练习题整理
查看>>
android与javaee通信:登录界面超级简化版
查看>>
Nhibernate3.3.3sp1基础搭建测试
查看>>
Python之模块与包
查看>>
C++中获取文件大小的几种途径汇总~
查看>>
JavaScript原始基础
查看>>
JDBC_基础6步骤- 及优化
查看>>
WCM重启报数据库启动错误
查看>>