`
standalone
  • 浏览: 597962 次
  • 性别: Icon_minigender_1
  • 来自: 上海
社区版块
存档分类
最新评论
文章列表
http://leetcode.com/onlinejudge#question_132 Question: Given a string s, partition s such that every substring of the partition is a palindrome. Return the minimum cuts needed for a palindrome partitioning of s. For example, given s = "aab", Return 1 since the palindrome partitioning [& ...

pthreads tutorial

    博客分类:
  • c
https://computing.llnl.gov/tutorials/pthreads/
Quite good article!!! http://www.unicon.net/node/740
在这个blog上学习twisted。 http://blog.163.com/gzjck_gshock/blog/static/77206203201291461538770/ 里面的一个关于DeferredList的例子一开始对语法不太理解,copy并run了一遍就理解了,把代码贴在这里留作以后借鉴。 connecttest.py: from twisted.internet import reactor, defer, protocol class CallbackAndDisconnectProtocol(protocol.Protocol): def conn ...
http://pcottle.github.com/learnGitBranching/
http://oss.oetiker.ch/rrdtool/tut/rrdtutorial.en.html RRD: Round Robin Database. RRDtool originated from MRTG (Multi Router Traffic Grapher). MRTG started as a tiny little script for graphing the use of a university's connection to the Internet. Terminology: Please read: http://bbs.chinaunix.net ...
Do you know the output of the code below: (function() { console.log(typeof foo); // function pointer console.log(typeof bar); // undefined var foo = 'hello', bar = function() { return 'world'; }; function foo() { return 'hello'; ...
Chapter 3 Scoping and functions Scoping rules in Javascript: 1. Variable declarations are in scope from their point of declaration to the end of the function within which they are declared, regardless of block nesting. Look at this example: if(window){   var x = 13; } alert(x);  // 13 2. Named ...
How to perform a batch delete in T-SQL http://resources.mdbitz.com/2010/03/how-to-perform-a-batch-delete-in-t-sql/
http://www.perlmonks.org/?node_id=57193 system("wc -l"); Will call the given command and return the return value of that command. This is usually not what you want, because most of the times wc -l will mean that you want to get the number of lines back from that call and not if that call w ...
看这个分析的吧: http://uniseraph.iteye.com/blog/439873
很不错,从这个code和DiaoCow那里可以学到不少东西! git repo: https://github.com/evanmiller/tinymq http://diaocow.iteye.com/blog/1734253

erl init stop

一直疑惑诸如command line erl -noshell -s Module Function Arguments -s init stop 后面加的init stop是干什么用的,看了stackoverflow上面一个问答清楚了: http://stackoverflow.com/questions/5269300/run-erlang-application-without-terminal-depending One useful variation is to also call the stop/0 function of the init module so that ...

Makefile tutorial

Old but good. http://www.codeproject.com/Articles/31488/Makefiles-in-Linux-An-Overview You should also notice the use of special characters (- and @) preceding the commands. As explained before, - tells make to continue processing even an error occurs and @ tells make not to print command before e ...
http://www.perlmonks.org/index.pl?node_id=287647 open FILEHANDLE, 'somefile.txt' or die $!; my $string = do { local $/; <FILEHANDLE> }; The above idiom is a consise way to "slurp" the entire contents of a file into a scalar without using a loop, such as: open FILEHANDLE, 'somefile. ...
Global site tag (gtag.js) - Google Analytics