psutil是python的一个用于获取cpu信息的模块,非常好使,以下附上官方的一些example:
CPU-> Examples>>> import psutil>>>
psutil.cpu_times()scputimes(user=3961.46, nice=169.729, syst...
分类:
其他好文 时间:
2014-06-09 19:36:32
阅读次数:
418
原题地址:https://oj.leetcode.com/problems/simplify-path/题意:Given
an absolute path for a file (Unix-style), simplify it.For example,path="/home/",
=>"/home...
分类:
编程语言 时间:
2014-06-09 19:13:54
阅读次数:
181
Map-reduce是一种优雅的数据处理方式,本文通过三个例子介绍如何用python在linux的管道进行map-reduce编程,本文写的所有map-reduce程序都可以原封不动的放在Hadoop下运行,很容易在大数据集上扩展。
分类:
其他好文 时间:
2014-06-09 19:11:44
阅读次数:
253
原题地址:https://oj.leetcode.com/problems/scramble-string/题意:Given
a strings1, we may represent it as a binary tree by partitioning it to two
non-empty su...
分类:
编程语言 时间:
2014-06-09 19:02:59
阅读次数:
197
1. python -m cProfile myprogram.py2. 使用import
profile模块import profiledef profileTest(): ...if __name__ == "__main__":
profile.run("profileTest()")3......
分类:
编程语言 时间:
2014-06-09 18:59:10
阅读次数:
219
原题地址:https://oj.leetcode.com/problems/search-in-rotated-sorted-array/题意:Suppose
a sorted array is rotated at some pivot unknown to you beforehand.(i.e...
分类:
编程语言 时间:
2014-06-09 18:43:14
阅读次数:
273
转载地址:http://www.cnblogs.com/kekec/archive/2010/08/09/1795581.htmlEclipse版本是:Indigo(3.8)以下是一些关键步骤:其中http://subclipse.tigris.org/update_1.6.x是SVN插件的下载站点...
分类:
系统相关 时间:
2014-06-09 18:03:30
阅读次数:
271
关于数据结构与算法讲解的书籍很多,但是用python语言去实现的不是很多,最近有幸看到一本这样的书籍,由Brad Miller and David
Ranum编写的《Problem Solving with Algorithms and Data Structures Using Python》.....
分类:
编程语言 时间:
2014-06-09 16:16:53
阅读次数:
276
Metasploit更新,官方放弃SVN,开始使用GIT有一段时间没有写文章了,今天翻译一篇文章吧。以后Metasploit更新,请不要再使用下面的方法了1svn
co https://www.metasploit.com/svn/framework3/trunk请使用GIT来进行更新1git cl...
分类:
Web程序 时间:
2014-06-09 15:32:47
阅读次数:
380
搭建SVN服务,有效的管理代码,以下三步可以快速搞定。1、安装 #yum install
subversion 判断是否安装成功#subversion -v svnserve, version 1.6.11
(r934486)出现上面的提示,说明安装成功。 如果提示如下:-b...
分类:
其他好文 时间:
2014-06-09 14:30:46
阅读次数:
315