摘要: 模拟类DescriptionIn a modernized warehouse, robots are used to fetch the goods. Careful planning is needed to ensure that the robots reach their destinations without crashing into each other. Of course, ... 阅读全文
posted @ 2009-09-28 23:28 Weiyu Wang 阅读(479) 评论(0) 推荐(0) 编辑
摘要: 模拟类DescriptionLet S = s1 s2...s2n be a well-formed string of parentheses. S can be encoded in two different ways: q By an integer sequence P = p1 p2...pn where pi is the number of left parentheses bef... 阅读全文
posted @ 2009-09-28 12:00 Weiyu Wang 阅读(557) 评论(0) 推荐(0) 编辑
摘要: 输入字符串为二叉树的先根遍历(Pre-order string),可采用堆栈或者递归。一般pre-order 字符串计算使用递归, post-order 字符串计算使用堆栈DescriptionWFF 'N PROOF is a logic game played with dice. Each die has six faces representing some subset of the p... 阅读全文
posted @ 2009-09-28 03:29 Weiyu Wang 阅读(849) 评论(0) 推荐(0) 编辑
摘要: 一共四种可能的情况1) 4s +  d  〉0,ssssdssssdss2)3s + 2d 〉 0,sssddsssddss3)2s + 3d 〉 0,ssdddssdddss4)1s + 4d 〉 0,sddddsddddsd并且对于给定的s和d, year sum: 1)〉 2) 〉 3) 〉 4)DescriptionAccounting for Computer Mac... 阅读全文
posted @ 2009-09-28 00:18 Weiyu Wang 阅读(425) 评论(0) 推荐(0) 编辑