李景旺的博客

www.jingwangl.com

1600:Patrol Robot

Patrol Robot 这个题还是DFS,不过每个状态除了记录位置之外,还要记录剩余穿越次数,这样一来就变成了三维DFS。对于值为1的点如果剩余穿越次数大于0且该状态未遍历过的话也可以访问。像这种四个方向的话用常量数组比较方便,没必要搞个二重循环,容易出bug。 #include&...

2018-08-10 00:56:31

阅读数:18

评论数:0

253:Cube painting

253:Cube painting开始的想法:骰子无论怎么转,每个数字和其对面的数字的对应关系永远不会改变,所以只需要比较两个骰子的三对数字是否相同即可,也的确AC了,但是后来想想不太对。#include<cstdio> #include&amp...

2018-04-12 12:42:34

阅读数:24

评论数:0

227:Puzzle

A children’s puzzle that was popular 30 years ago consisted of a 5×5 frame which contained 24 smallsquares of equal size. A unique letter of the alph...

2018-04-05 13:17:58

阅读数:29

评论数:0

1586:Molar mass

An organic compound is any member of a large class of chemicalcompounds whose molecules contain carbon. The molarmass of an organic compound is the m...

2018-04-04 22:11:03

阅读数:11

评论数:1

401:Palindromes

PalindromesTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 1253    Accepted Submission(s): 50...

2018-04-03 23:17:37

阅读数:28

评论数:1

10082:WERTYU

WERTYUTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 9533 Accepted: 4543Description A common typing error is to place the hands on the key...

2018-04-03 23:15:35

阅读数:19

评论数:1

提示
确定要删除当前文章?
取消 删除
关闭
关闭