------------------------------------------------------------------------------------------Nginx启动:cd
/usr/local/nginx/sbin./nginxTomcat启动:cd /home/cms...
分类:
其他好文 时间:
2014-05-16 04:19:46
阅读次数:
243
uva 10391 Compound Words (字符串-hash)
题目大意:
有一堆按照字典序排好的字符串,问你有多少字符串是由其它两个字符串组成。
解题思路:
如果用两个字符串拼接看拼接好的字符串是否在字典中,一定会超时。
我们可以逆向,由于字符串的长度不是很长,所以把一个字符串拆为两个字符串看这两个字符串是否都在字典中即可
解题代码一:
判断字符串是否在字典中,可以用STL set,也是轻松AC
解题代码二:
判断字符串是否在字典中,可以用hash,于是手写ha...
分类:
其他好文 时间:
2014-05-16 02:48:12
阅读次数:
377
#所有需要安装的包都在contribs目录里。faac1.#cd/usr/local/src/contribs2.[root@...contribs]#tarzxvffaac-1.28.tar.gz3.[root@...contribs]#cdfaac-1.284.[root@...faac-1.28]#./configure--prefix=/usr/local/--enable-shared5.[root@...faac-1.28]#make&&makeinst..
分类:
其他好文 时间:
2014-05-15 19:16:58
阅读次数:
549
#1.建议在opt下面操作,我的opt是一个单独分区,创建一个swap的文件夹
cd/opt
mkdirswap
#2.创建一个2GB大小的文件
ddif=/dev/zeroof=swapfilebs=1024count=2048000
#3.转换激活swap分区
mkswapswapfile
swaponswapfile
#4.查看扩充后的大小
free-m
#5.写入/etc/fstab文件,在..
分类:
其他好文 时间:
2014-05-15 18:46:17
阅读次数:
256
通过brew 安装:brew install mariadb初始化数据库cd
/usr/local/Cellar/mariadb/10.0.10/scriptsmysql_install_db --user=`root`
--basedir="$(brew --prefix mariadb)" --...
分类:
数据库 时间:
2014-05-15 17:53:53
阅读次数:
913
题目:在一个n*m的迷宫中有一个轮子,轮子的每个72°的扇面被涂上一种不同的颜色。
轮子可以移动到上下左右四个方向的格子中,每次移动到相邻格子中,轮子转动72°。
每个单位时间轮子可以做两种运动:
1.移动到相邻格子;2.改变朝向,面向原来的左、右方(朝向改变90°),但不转动。
初始时轮子在'...
分类:
其他好文 时间:
2014-05-15 12:28:14
阅读次数:
450
Problem C: The Dragon of LoowaterOnce upon a
time, in the Kingdom of Loowater, a minor nuisance turned into a major
problem.The shores of Rellau Creek...
分类:
其他好文 时间:
2014-05-15 09:53:27
阅读次数:
254
(1)cd
/usr/local/php-5.2.17/ext/mysqli(2)输入/usr/local/php/bin/phpize 回车(3)./configure
--prefix=/usr/local/mysqli --with-php-config=/usr/local/php/bin....
分类:
其他好文 时间:
2014-05-15 09:34:06
阅读次数:
292
【题目】
A sequence of N positive integers (10 N , each of them less than or equal 10000, and a positive integer S (S <
100 000 000) are given. Write a program to find the minimal length of the subse...
分类:
其他好文 时间:
2014-05-15 07:58:17
阅读次数:
329
2. md md是英文make directory(创建目录)的缩写 [功能] 创建一个子目录
[格式] md [C:]path [举例] 用md 建立一个叫做purple的目录 3. cd cd是英文change directory(改变目录)的缩写
[功能] 改变或显示当前目录 [格式] cd ...