Skip to content

Instantly share code, notes, and snippets.

View chenko515's full-sized avatar
💭
Alive

NM055 chenko515

💭
Alive
View GitHub Profile
@chenko515
chenko515 / python3 http server
Last active December 19, 2015 19:28
start an quick http server easily under your current working directory with the help of the built-in http.server module in python3, using bash
python3 -m http.server
@chenko515
chenko515 / python3 timeit
Last active December 19, 2015 19:19
python3的timeit模块,python3计时用法 using python3
if __name__ == '__main__':
import timeit
print(timeit.timeit("test()", setup="from __main__ import test"))
# http://docs.python.org/3.3/library/timeit.html
timeit.timeit(stmt='pass', setup='pass', timer=<default timer>, number=1000000)
Create a Timer instance with the given statement, setup code and timer function and run its timeit() method with number executions.
@chenko515
chenko515 / linux aliases file
Last active December 19, 2015 18:29
linux aliases defined in the configure file: "~/.bash_aliases", using any text editor
# aliases defined by chenko
# medit ~/.bash_aliases fast:
alias al="sudo medit ~/.bash_aliases"
# goagent
alias go="python /home/chenko/Beckup/Linux/App/goagent-goagent-24bca79/local/proxy.py"
# javascript enginge rhino1.7.4
alias rh="java -jar /home/chenko/Beckup/Linux/App/rhino1_7R4/js.jar"