Problem FMarblesInput:standard
inputOutput:standard outputI have some (say,n) marbles (small glass balls) and I
am going to buy some boxes to store th...
分类:
其他好文 时间:
2014-05-26 14:45:04
阅读次数:
319
Problem Description
Today is Yukari's n-th birthday. Ran and Chen hold a celebration party for her. Now comes the most important part, birthday cake! But it's a big challenge for them to place n ca...
分类:
其他好文 时间:
2014-05-26 04:38:35
阅读次数:
239
题目链接:点击打开链接
题意:有两种操作,合并集合,查询第K大集合的元素个数。(总操作次数为2*10^5)
Treap模板(静态数组)
#include
#include
#include
#include
#include
const int maxNode = 500000 + 100;
const int inf = 0x3f3f3f3f;
struct Tr...
分类:
其他好文 时间:
2014-05-24 23:18:09
阅读次数:
522
点击打开链接
题意:
集合S支持一下四种操作:
INSERT(S,x) : 如果S中没有x,则插入x
DELETE(S,x): 如果S中有x,则删除x
K-TH(S): 输出S中第K小的数
COUNT(S,x): 统计S中小于x的数有多少个
一共有Q(1 ≤ Q ≤ 200000)次操作。
Treap模板。。
#i...
分类:
其他好文 时间:
2014-05-24 18:03:11
阅读次数:
213
介绍一个多选list
/*
* Copyright (C) 2008 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with th...
分类:
其他好文 时间:
2014-05-23 00:52:57
阅读次数:
455
usingandusing namespacehave validity only in
the same block in which they are stated or in the entire source code file if
they are used directly in th...
分类:
其他好文 时间:
2014-05-22 02:08:48
阅读次数:
268
http://acm.hdu.edu.cn/showproblem.php?pid=4393题意:有n个人,i-th人第一秒速度为Fi/s,之后Si/s。每一秒末,跑在最前面的人消失,如果有多个人同时在最前面,id最小的人消失。输出消失顺序。题解:因为Si最多只有100个,所以对Si进行操作。采用优...
分类:
其他好文 时间:
2014-05-21 19:23:37
阅读次数:
270
现在很多语言都内置了线程池实现,但C++中却没有。本文列举一些C++实现的线程池工具。Boost.Threadpool
项目首页:http://threadpool.sourceforge.net
Boost.Threadpool是一个基于Boost、跨平台的C++线程池库。Boost.Th...
分类:
编程语言 时间:
2014-05-21 18:54:30
阅读次数:
363
介绍一个grid layout 顺序显示的代码
LayoutAnimation1.java
/*
* Copyright (C) 2007 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use th...
分类:
其他好文 时间:
2014-05-21 16:58:47
阅读次数:
214
response.buffer=false
'为防止程序陷入死循环,初始化一些最大重试值
Dim MaxPassLen,MaxPassAsc
MaxPassLen=20 '密码最大长度
MaxPassAsc=20
'==== 字符转换
Function bytes2BSTR(vIn)
strReturn = ""
For j = 1 To LenB(vIn)
Th...
分类:
其他好文 时间:
2014-05-20 14:52:56
阅读次数:
438