Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center).For example, this binary tree is symmetric: 1 / \ ...
分类:
其他好文 时间:
2015-06-19 10:12:00
阅读次数:
128
ubuntu可以利用apt-mirror下载Ubuntu源和openstack源。安装下载工具apt-mirrorapt-getinstallapt-mirror修改源配置,使用souhu源vi/etc/apt/mirror.list加入以下内容:#############config##################
#
#setbase_path/var/spool/apt-mirror
setbase_path/home/openstac..
分类:
系统相关 时间:
2015-06-18 22:21:15
阅读次数:
188
sun solaris低版本存在bash漏洞,通过卸载或者升级解决问题。
1、所有的pkg安装包下载地址:
http://mirror.opencsw.org/opencsw/allpkgs/
2、下载安装:
#gunzip bash-4.3.33,REV=2015.02.15-SunOS5.10-sparc-CSW.pkg.gz
# pkgadd -d bash...
分类:
系统相关 时间:
2015-06-18 13:43:18
阅读次数:
223
debian安装和基本设置创建:更新:06-18-2015 11:30环境 debian8-xfce4-amd64下载 自行从http://www.debian.org/mirror/list用Ctrl-F查找“zh”,然后进入相应站点的../debian-cd/ 比如,http://debian....
分类:
其他好文 时间:
2015-06-18 13:24:39
阅读次数:
153
一、storm伪分布式安装
(一)环境准备
1、OS:debian 7
2、JDK 7.0
(二)安装zookeeper
1、下载zookeeper并解压
wget http://mirror.bit.edu.cn/apache/zookeeper/zookeeper-3.4.6/zookeeper-3.4.6.tar.gz
tar -zxvf zookeeper-3.4...
分类:
其他好文 时间:
2015-06-16 19:23:42
阅读次数:
196
FIO是测试IOPS的非常好的工具,用来对硬件进行压力测试和验证,支持13种不同的I/O引擎,包括:sync,mmap, libaio, posixaio, SG v3, splice, null, network, syslet, guasi, solarisaio 等等。fio 官网地址:htt...
分类:
系统相关 时间:
2015-06-16 16:33:22
阅读次数:
274
代码不做注释了,因为我是把这个当作笔记来做的,如果感兴趣Go语言,加我QQ 我们一起学习这门新兴的语言.
服务端:Message_server.go
package main
import (
"container/list"
"encoding/json"
"fmt"
Json "go-json" //go-simplejson
"net"
"sync"
"time"
)
...
分类:
编程语言 时间:
2015-06-16 14:45:23
阅读次数:
149
安装配置NFS服务(需要安装两个包nfs-utils和rpcbind)#yuminstall-ynfs-utils#yuminstall-yrpcbind#vi/etc/exports/home/192.168.1.0/24(rw,sync,all_squash,anonuid=501,anongid=501)#servicercpbindstart#servicenfsstart#serviceiptablesstop#getenforce此时打开另外一台虚..
分类:
其他好文 时间:
2015-06-16 08:03:42
阅读次数:
148
检查已安装版本#检查是否安装了低版本的SVN[root@localhost /]# rpm -qa subversion#卸载旧版本SVN[root@localhost modules]# yum remove subversion#wgethttp://mirror.centos.org/cent...
分类:
其他好文 时间:
2015-06-15 23:44:00
阅读次数:
158
这种方法也是万万没想到的~
#include
#define maxn 1000000+5
using namespace std;
int f[maxn];
int n,m;
int main()
{
cin.sync_with_stdio(false);
while(cin>>n>>m)
{
fill(f,f+maxn,0);
for(int i=0;i<n;i++)
{
...
分类:
其他好文 时间:
2015-06-14 09:31:37
阅读次数:
111