自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(66)
  • 资源 (3)
  • 收藏
  • 关注

原创 解决Google Calendar不能取消订阅的小问题

应该是个bug,Google最近在忙什么,不把原来的产品做好...解决方法很简单,把日历的名字改成纯字母的,避免特殊符号就行了...

2012-05-27 16:42:20 451

原创 Install Mint 12 (Ubuntu 11.10) on Thinkpad T420

1) 调节风扇转速(install thinkfan)refer: [url]http://ubuntuforums.org/showthread.php?t=1872633[/url]1. enable power saving render, active state power mgmt: in /etc/default/grubCode:[quote]GRUB_CMDL...

2012-03-21 17:07:44 286

原创 [转载]Thinkpad T410 安装 Ubuntu10.04

http://blog.sina.com.cn/s/blog_5038ce7a0100qfyj.htmlThinkpad T410 安装 Ubuntu10.04 (2011-03-06 14:43:06)转载▼标签: linux ubuntu 10.04 thinkpadt410 杂谈 分类: LinuxThinkpad T410 下安装 Ubuntu10.04 移动硬盘上...

2012-03-18 10:48:43 638

原创 又一次安装thrift

with cpp, java, pythonmake install搞了N次,Ant总提示JAVA_HOME不对最后看这篇博文[url]http://jayant7k.blogspot.com/2010/04/intro-to-thrift.html[/url]原来需要管理员权限,su一下,再export JAVA_HOME...另外make自带的tutorial cpp的...

2012-02-18 12:25:44 126

原创 lower_bound and upper_bound

[code="c++"] /** * @brief Finds the first position in which @a val could be inserted * without changing the ordering. * @param first An iterator. * @param last Ano...

2012-02-09 00:36:13 118

原创 HDU 3954

线段树变种,也是在2logn段上面做文章[code="c++"]/* * Author: rush * Filename: hdu3954.cpp * Timestamp: 2012-02-04 23:26:50 CST */#include #include #include #include #include #include #incl...

2012-02-05 10:43:14 143

原创 HDU 4027

线段树变种在2logn段上面做文章,swap(x, y)太阴了...[code="c++"]/* * Author: rush * Filename: segment_sum2.cpp * Timestamp: 2012-02-04 19:12:20 CST */#include #include #include #include #inclu...

2012-02-04 22:09:25 69

原创 makefile模板

[code]PROG := _test_keyword_extractorSRCS := g_keyword_extractor.c _test_keyword_extractor.cDEPS := genericOBJS := ${SRCS:%.c=%.o}# Compiler and flagsCC := g++LD := g++INCLUDE_DI...

2011-12-30 17:53:53 77

原创 VNC Server配置

参见http://bobpeers.com/linux/vnc1) 添加用户$ vim /etc/sysconfig/vncservers[code]# The VNCSERVERS variable is a list of display:user pairs.## Uncomment the lines below to start a VNC server ...

2011-12-26 23:56:47 122

原创 Python 自动登录网站(处理Cookie)

[code="python"]def login(): cj = cookielib.CookieJar() opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(cj)) login_url = r'http://zhixing.bjtu.edu.cn/member.php?mod=logging&a...

2011-12-10 15:51:48 463

原创 [2011-12-06]调研membase

1、安装,初步使用,2目前该开源项目的开发状况,代码量,业界使用状况3、调研其设计机制(内存管理,数据持久化,分布式存储管理等),功能,性能4、测试 接下来就是调研membase。membase具有持久化存储,分布式集群管理的功能。使用了erlang和C++作为开发语言,erlang用来管理集群和分布式存储,C++用来实现具体的存储。关于membase的调研内容有...

2011-12-06 16:52:03 71

原创 thrift配置

实验室不给root权限的纠结的配置[code="java"]./configure --prefix=/home/michael/bin --with-boost=/home/michael/lib/boost_1_47_0 --with-libevent=/home/michael/bin/ --without-python --with-cpp --without-csharp -...

2011-12-05 23:02:50 100

原创 vimrc备份

[code="java"] 1 " vimrc by digiter@126.com 2 3 " General 4 set encoding=UTF8 5 set fileencodings=UTF8,GBK " text encoding 6 set nocompatible " not compatible vith vi...

2011-12-03 14:06:12 89

原创 SSH 不输入密码登录

[code]ssh-keygen -t rsassh-copy-id -i ~/.ssh/id_rsa.pub username@myurl[/code]

2011-11-29 13:21:04 97

原创 [转载]screenrc配置

[code="java"]hardstatus alwayslastlinehardstatus string "%{.bW}%-w%{.rY}%n %t%{-}%+w %=%{..G} %c:%s "startup_message offvbell offbind ' ' title[/code]screen是个好东西,这几天一直在用它。假如遇到一些比较费时间...

2011-11-13 23:19:56 385

原创 vimrc备份

[code="java"]" vimrc by digiter@126.com" Generalset encoding=utf-8 " text encodingset nocompatible " not compatible vith viset autoread " auto load file modified outsidefil...

2011-11-12 18:49:49 82

原创 ICPC编码建议

写代码最重要的是清晰,包括思路的清晰和代码结构的清晰。我们无法保证写的代码一定是正确的,但我们可以保证自己是在头脑清晰的情况下书写,并且通过不断的练习,用更加清晰的代码结构实现。越清晰,程序就越可能正确,并且即使出错也很容易看到问题。[code="c++"]0)在能过题的情况下,最朴素最好写的方式就是最好的。1)double x = 0;scanf("%lf", x...

2011-10-28 09:52:20 255

原创 [2011-10-13] HBase Pseudo-distributed

conf/hbase-site.xml[code="xml"] hbase.rootdir hdfs://localhost:54310/hbase[/code]特别注意在ubuntu中,将/etc/hosts文件改为[code]127.0.0.1 localhost#127.0.1.1 rush-Vostro-1400127....

2011-10-13 16:06:50 86

原创 [2011-09-22] 通过多次ssh部署文件到服务器的脚本

用于将写好的程序部署到服务器file: cplab[code]#!/bin/shif [ ! $1 ]then echo 'err: no input file'; exitfiHOSTNAME=$(hostname)if [ "$HOSTNAME" = 'rush-Vostro-1400' ]then dest='rush@mylab'...

2011-09-22 20:58:34 105

原创 [2011-09-21] Hadoop and HBase 配置汇总

Hadoopconf/masters[code="xml"]hadoop-master[/code]conf/slaves[code="xml"]hadoop-masterhadoop-slave1hadoop-slave2[/code]conf/hadoop-env.sh[code="xml"]export JAVA_HOME=/h...

2011-09-21 21:36:04 178

[2011-09-20] HBase configuration

http://hbase.apache.org/book/hadoop.html2.3. Hadoop还得自己build Hadoop,不然会因为缺少a durable sync而丢失数据,真贱……暂时没管2.3.1. Hadoop Security2.3.2. dfs.datanode.max.xcievers暂时没管http://hbase.apac...

2011-09-20 17:31:17 82

原创 [转载]全国高校IPv6地址分配情况

[code="java"]2001:DA8:0200::/48 清华大学2001:DA8:0201::/48 北京大学2001:DA8:0202::/48 北京邮电大学2001:DA8:0203::/48 北京航天航空大学2001:DA8:0204::/48 北京理工大学2001:DA8:0205::/48 北京交通大学2001:DA8:...

2011-09-16 16:17:54 1838

[2011-09-16] HBase configuration

环境java version "1.6.0"hadoop-0.20.203.0rc1hbase-0.90.4首先是quickstarthttp://hbase.apache.org/book/quickstart.html然后是各种配置…http://hbase.apache.org/book/os.html2.2. Operating System2....

2011-09-16 14:59:37 65

原创 [转载]TopCoder插件

转载自:http://acm.cugb.edu.cn/blog/?p=253首先我们到http://www.topcoder.com/tc?module=Static&d1=applet&d2=plugins(FTP上有)下载几个插件,主要是这三个:Plugin Name: TZTesterPlugin Name: CodeProcessorPlugin Name: Fil...

2011-09-08 22:13:09 156

原创 Geany snippets

[code="java"]header=/*\n * Author: {developer}\n * Filename: {filename}\n * Timestamp: {datetime}\n */\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include...

2011-09-08 00:04:43 85

原创 Python urllib2 Note

http://docs.python.org/library/urllib2.html记一些我的理解通常情况需要urllib2.build_opener([handler, ...])生成一个opener,并通过该opener来访问URL[code="python"]proxy_handler = urllib2.ProxyHandler({'http': 'http:...

2011-08-24 17:57:38 91

原创 Django Notes

管理静态文件,如CSS, JS等https://docs.djangoproject.com/en/dev/howto/static-files/

2011-08-22 22:21:34 64

原创 UVALive 5112 - Sales Prediction

封装了矩阵类比赛做得很郁闷,为什么别人写得很长、很罗嗦的代码可以过题,而我的总是过不了呢?...[code="c++"]/* * Author: rush * Created Time: 2011年01月05日 星期三 19时39分08秒 * File Name: icpc/20100105/E2.cpp */#include #include #incl...

2011-01-06 10:19:30 78

原创 PyDev Color Theme

[code]# Mon Jan 03 21:36:09 CST 2011# pydev color theme refering gedit default color theme/instance/org.python.pydev/STRING_COLOR=255,0,255/instance/org.python.pydev/COMMENT_COLOR=0,0,255/...

2011-01-03 21:43:09 104

原创 hdu 3236

终于能过这道题了,算是背包必做题之一吧[code="c++"]/* * Author: rush * Created Time: 2010年12月12日 星期日 12时34分31秒 * File Name: icpc/hdu3236_3.cpp */#include #include #include #include #include #incl...

2010-12-12 14:10:21 135

原创 pku 1018

写了两三个版本,最后这个效率最高[code="c++"]#include #include #include #include #include #include #include #include #include #define out(v) cout

2010-12-11 15:18:29 75

原创 布斯(Booth)乘法

源自http://watashi.ws/blog/1515/zojmonthly1010/[code="c++"]inline long long mul(long long lhs, long long rhs) { long long lhs2 = lhs % 100000; long long rhs2 = rhs % 100000; return ((lhs / 100...

2010-10-07 19:59:01 1414

原创 高斯消元

[code="java"]import java.util.*;import java.io.*;import java.math.*;class Fraction { BigInteger a = BigInteger.ZERO, b = BigInteger.ONE; Fraction() { } Fraction(BigInteger a, ...

2010-10-07 14:18:44 77

原创 整数划分

[code="c++"]#include #include #include #include #include #include #include #include #include #define out(v) cout

2010-10-07 10:38:20 86

原创 Treap

[code="c++"]// Treap// Tested: bjtu1057, hdu1004, pku1002typedef int KEY;typedef int VALUE;struct node_t { int ch[2], pr; KEY key; VALUE value;} T[maxn];int size; // init: size = 0...

2010-09-18 22:19:34 70

原创 矩阵快速幂

[code="c++"]typedef LL matrix[55][55];void ident(int size, matrix x){ for (int i = 0; i < size; ++i) for (int j = 0; j < size; ++j) x[i][j] = (i == j ? 1 : 0);}v...

2010-09-18 14:24:36 89

原创 maximum clique 最大团

最大团模板[code="c++"]#include #include #include #include #include #include #include #include #define out(v) cout

2010-09-02 18:12:23 87

原创 计算Jacobi符号

Quadratic reciprocityThe Jacobi symbol, (m/n), is defined whenever n is an odd number. It has the following properties that enable it to be easily computed. * (a/n) = (b/n) if a = b mod n. ...

2010-08-31 13:15:49 1482

原创 Java 高效I/O

[code="java"] static BufferedReader cin = new BufferedReader(new InputStreamReader(System.in)); static BufferedWriter cout = new BufferedWriter(new OutputStreamWriter(System.out));BufferedRead...

2010-08-19 16:54:34 66

原创 DLX pku 3076

标准数独,精确覆盖[code="c++"]// pku3076.cpp#include #include #include #include #include #include #include #include #include #define out(v) cout

2010-08-11 23:45:01 112

MySQL 5.1参考手册

终于找到一个能打开的chm格式的MySQL 5.1手册,非常高兴,于是传上来分享 原下载地址: http://developers.sun.com.cn/mysql/

2009-10-23

AMD的CPU编号封装说明

讲解AMD CPU型号的说明,包括Duron(毒龙), Athlon(速龙), Sempron (闪龙),Barton(巴顿)等产品

2009-05-18

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除