题目传送门 1 /* 2 线段树的单点更新:有一个交叉更新,若rank=1,or;rank=0,xor 3 详细解释:http://www.xuebuyuan.com/1154895.html 4 */ 5 #include 6 #include 7 #include 8 #i...
分类:
其他好文 时间:
2015-04-08 14:44:04
阅读次数:
111
背包密码
Time Limit: 1000ms
Memory Limit: 65536KB
64-bit integer IO format: %lld Java class name:
Main
Submit
Status
PID: 29141
背包密码系统是一种非常经典的公钥密码系统,这种密码系统加密过程如下:
...
分类:
其他好文 时间:
2015-04-08 13:19:19
阅读次数:
171
Write a function that takes an unsigned integer and returns the number of ’1' bits it has (also known as the Hamming weight).For example, the 32-bit i...
分类:
其他好文 时间:
2015-04-08 12:21:36
阅读次数:
101
#include
#include
#define CHAR_BIT 8
using namespace std;
template
class bitset
{
typedef unsigned long _Ty;
friend ostream & operator &_R)
{
for(size_t _P=_N;_P>0;)
_O<<(_R.test(--_P)?'1...
分类:
编程语言 时间:
2015-04-08 11:04:38
阅读次数:
160
Write a function that takes an unsigned integer and returns the number of ’1' bits it has (also known as theHamming weight).For example, the 32-bit in...
分类:
其他好文 时间:
2015-04-08 07:58:32
阅读次数:
106
题目链接:Gray Code
The gray code is a binary numeral system where two successive values differ in only one bit.
Given a non-negative integer n representing the total number of bits in the code, print th...
分类:
其他好文 时间:
2015-04-07 23:34:18
阅读次数:
318
J. 鸣人的查克拉
Time Limit: 1000ms
Memory Limit: 65536KB
64-bit integer IO format: %lld Java class name: Main
Submit Status PID:
29065
《火影忍者》中,在忍者们使用忍术的时候,需要一定的查克拉(可以看成是一种体力值)。在战斗前,大家都希望...
分类:
其他好文 时间:
2015-04-07 21:42:51
阅读次数:
171
L. 斩
Time Limit: 1000ms
Memory Limit: 65536KB
64-bit integer IO format: %lld Java class name:
Main
Submit
Status
PID: 29379
在电影里面,我们经常可以看到武士们拔出刀,然后一刀斩下去,结果………………………………一张纸片被砍成...
分类:
其他好文 时间:
2015-04-07 21:42:14
阅读次数:
112
World IslandsTime Limit: 1000msMemory Limit: 32768KBThis problem will be judged onHDU. Original ID:340564-bit integer IO format:%I64d Java class name:...
分类:
其他好文 时间:
2015-04-07 17:21:14
阅读次数:
121
Number of 1 Bits
Write a function that takes an unsigned integer and returns the number of ’1' bits it has (also known as the Hamming
weight).
For example, the 32-bit integer ’11' has bin...
分类:
其他好文 时间:
2015-04-07 15:43:06
阅读次数:
125