SHELL学习笔记----IF条件判断,判断条件前言: 无论什么编程语言都离不开条件判断。SHELL也不例外。if list then do something here elif list then do another thing here else do something else here...
分类:
其他好文 时间:
2014-06-14 09:40:46
阅读次数:
204
Bootstrap 101 Template Toggle navigation Brand
Link Link Dropdown Action Another action Something else here Separated link One
more separated link Sub...
分类:
其他好文 时间:
2014-06-12 18:58:06
阅读次数:
398
Running KVM and Openvswitch on Ubuntu 12.10
I’ve got an aging VMWare ESXi 4.0 server that needs to be replaced with
something a little more modern and...
分类:
其他好文 时间:
2014-06-09 18:07:21
阅读次数:
324
You can know form the name that the HTMLParser
is something used to parse HTML files. In python, there are two HTMLParsers. One
is the HTMLParser clas...
分类:
编程语言 时间:
2014-06-05 12:46:16
阅读次数:
1294
1. 最基本的读文件方法:# File: readline-example-1.pyfile =
open("sample.txt")while 1: line = file.readline() if not line: break pass # do
something 一行一行得从文件读数据....
分类:
编程语言 时间:
2014-05-29 01:34:30
阅读次数:
402
如下可能是最简单的下拉列表了: DropDown Action Another action
Something else here Separated link 这个...
分类:
其他好文 时间:
2014-05-28 15:32:22
阅读次数:
234
方法一:适用于App不适用于UIWebViewNSURL *iTunesURL;// Process
a LinkShare/TradeDoubler/DGM URL to something iPhone can handle-
(void)openReferralURL:(NSURL *)ref...
分类:
移动开发 时间:
2014-05-25 14:02:32
阅读次数:
377
背景
大家都知道线程之间共享变量要用volatile关键字。但是,如果不用volatile来标识,会不会导致线程死循环?比如下面的伪代码:
static int flag = -1;
void thread1(){
while(flag > 0){
//wait or do something
}
}
void thread2(){
//do something
f...
分类:
编程语言 时间:
2014-05-25 10:24:14
阅读次数:
220
Kuriyama Mirai has killed many monsters and got many (namely n) stones. She numbers the stones from 1 to n.
The cost of the i-th stone is vi.
Kuriyama Mirai wants to know something about these sto...
分类:
其他好文 时间:
2014-05-25 07:24:48
阅读次数:
315