摘要: 题目传送门题意:可以交换两个相邻的数字顺序k次,问最后逆序对最少有多少分析:根据逆序数的定理如果逆序数大于0,那么必定存在1#include #include #include #include #include #include #include #include #include #includ... 阅读全文
posted @ 2015-09-12 20:53 Running_Time 阅读(431) 评论(0) 推荐(0) 编辑
摘要: 首先抱来Matrix67大牛的文章(修改部分内容):位运算简介及实用技巧(一):基础篇去年年底写的关于位运算的日志是这个Blog里少数大受欢迎的文章之一,很多人都希望我能不断完善那篇文章。后来我看到了不少其它的资料,学习到了更多关于位运算的知识,有了重新整理位运算技巧的想法。从今天起我就开始写这一系... 阅读全文
posted @ 2015-09-12 20:23 Running_Time 阅读(296) 评论(0) 推荐(0) 编辑
摘要: Problem Statement Cat Noku has just finished writing his first computer program. Noku's computer has m memory cells. The cells have addresses 0 throug 阅读全文
posted @ 2015-09-12 19:17 Running_Time 阅读(215) 评论(0) 推荐(0) 编辑