2018年8月17日

Fliptile POJ - 3279

摘要: Farmer John knows that an intellectually satisfied cow is a happy cow who will give more milk. He has arranged a brainy activity for cows in which the 阅读全文

posted @ 2018-08-17 10:54 Cute_Abacus 阅读(105) 评论(0) 推荐(0) 编辑

Catch That Cow POJ - 3278

摘要: Farmer John has been informed of the location of a fugitive cow and wants to catch her immediately. He starts at a point N (0 ≤ N ≤ 100,000) on a numb 阅读全文

posted @ 2018-08-17 10:53 Cute_Abacus 阅读(168) 评论(0) 推荐(0) 编辑

Dungeon Master POJ - 2251

摘要: You are trapped in a 3D dungeon and need to find the quickest way out! The dungeon is composed of unit cubes which may or may not be filled with rock. 阅读全文

posted @ 2018-08-17 10:51 Cute_Abacus 阅读(138) 评论(0) 推荐(0) 编辑

棋盘问题 POJ - 1321

摘要: 题目 在一个给定形状的棋盘(形状可能是不规则的)上面摆放棋子,棋子没有区别。要求摆放时任意的两个棋子不能放在棋盘中的同一行或者同一列,请编程求解对于给定形状和大小的棋盘,摆放k个棋子的所有可行的摆放方案C。 Input 输入含有多组测试数据。 每组数据的第一行是两个正整数,n k,用一个空格隔开,表 阅读全文

posted @ 2018-08-17 10:50 Cute_Abacus 阅读(89) 评论(0) 推荐(0) 编辑

2018年8月16日

Monkey and Banana HDU - 1069

摘要: 题目 A group of researchers are designing an experiment to test the IQ of a monkey. They will hang a banana at the roof of a building, and at the mean t 阅读全文

posted @ 2018-08-16 16:10 Cute_Abacus 阅读(112) 评论(0) 推荐(0) 编辑

Ignatius and the Princess IV HDU - 1029

摘要: 题目 "OK, you are not too bad, em... But you can never pass the next test." feng5166 says. "I will tell you an odd number N, and then N integers. There 阅读全文

posted @ 2018-08-16 16:09 Cute_Abacus 阅读(142) 评论(0) 推荐(0) 编辑

Max Sum Plus Plus HDU - 1024

摘要: 题目: Now I think you have got an AC in Ignatius.L's "Max Sum" problem. To be a brave ACMer, we always challenge ourselves to more difficult problems. N 阅读全文

posted @ 2018-08-16 16:06 Cute_Abacus 阅读(162) 评论(0) 推荐(0) 编辑

2018年8月12日

基本算法_位运算_lowbit

摘要: lowbit运算 lowbit(n)定义为非负整数n在二进制表示下“最低位的1及后面的所有0”构成的数值。比如二进制10011111010的lowbit就是最后两位10。 那么我们如何得到lowbit的值呢? 首先:取反。 ~ 10011111010 = 01100000101 然后:+1 0110 阅读全文

posted @ 2018-08-12 20:36 Cute_Abacus 阅读(491) 评论(0) 推荐(0) 编辑

导航