题目链接:
http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemId=5122
ZOJ Problem Set - 3740
Water Level
Time Limit: 2 Seconds Memory Limit: 65536 KB
Hangzhou is a beauti...
分类:
其他好文 时间:
2014-05-10 10:12:56
阅读次数:
432
修改.proje
修改.settings/org.eclipse.wst.common.component文件...
分类:
编程语言 时间:
2014-05-07 07:44:46
阅读次数:
356
题目大意:
给出m个询问,问【l,r】之间的和 ,求出有多少次询问不和之前的矛盾的。
思路分析:
用并查集记录当前节点到根节点的和。
#include
#include
#include
#include
#define maxn 222222
using namespace std;
int set[maxn];
int sum[maxn];
in...
分类:
其他好文 时间:
2014-05-07 07:35:05
阅读次数:
386
LRU Cache
Design and implement a data structure for Least Recently Used (LRU) cache. It should support the following operations: get and set.
get(key) - Get the value
(will always be posi...
分类:
其他好文 时间:
2014-05-07 07:16:21
阅读次数:
316
eshell是emacs shell的简称,是emacs自带的shell.开始设置的时候还在想是否要找到它的key map (eshell-mode-map?).
原来它是采用hook设置,如下所示
(add-hook 'eshell-mode-hook
(lambda ()
(local-set-key (kbd "C-j") 'switch-to...
分类:
其他好文 时间:
2014-05-07 05:25:39
阅读次数:
253
如果placeholderImage 为空的话,会出现显示不出下载的图片,应该给他一个展位图
[cell.imageView
setImageWithURL:imageUrl placeholderImage:nil options:SDWebImageLowPriority |
SDWebImageRetryFailed];
应该: [cell.imageView setI...
分类:
Web程序 时间:
2014-05-07 05:24:58
阅读次数:
685
简单谈谈 Python 中容器的遍历和一下小技巧。
1、遍历单个容器
下面代码遍历一个 List 结构,同样适用于 Tuple、Set 结构类型
>>> x = [1, 2, 3, 'p' , 'y']
>>> for v in x:
... print(x)
...
1
2
3
p
y
遍历字典 Dict 结构也是...
分类:
编程语言 时间:
2014-05-07 04:12:39
阅读次数:
395
package com.array;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Set;
import...
分类:
编程语言 时间:
2014-05-07 03:45:11
阅读次数:
365
(iOS开发)确保设置话筒模式成功 AudioSessionSetProperty...
分类:
移动开发 时间:
2014-05-06 15:05:42
阅读次数:
452