![](https://img-blog.csdnimg.cn/20201014180756724.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Python语言
iteye_1291
这个作者很懒,什么都没留下…
展开
-
python读写csv文件
python读写csv文件[code="java"]#!/usr/bin/python# -*- coding: UTF-8 -*-import csvdef writer (): aa = csv.writer(file('z.csv', 'wb')) aa.writerow(['c1', 'c2', 'c3']) lines = [ra...原创 2012-07-16 15:55:13 · 89 阅读 · 0 评论 -
python+web.py实现hello world
1,确定系统中存在python环境以下介绍基于ubnntu 12.04 amd64python 2.7.32,安装web.py[code="java"]wget http://webpy.org/static/web.py-0.37.tar.gztar -xvzf web.py-0.37.tar.gz cd web.py=0.37python setup....原创 2012-07-18 18:34:58 · 156 阅读 · 0 评论 -
【趣味shell&python】倒三角控制台输出图形
通过脚本实现如下效果1,python实现#!/usr/bin/python# filename:demo.py# -*- coding: UTF-8 -*-if __name__ == '__main__': n = 20 for i in range(1, n): m = i * 2 - 1 char1 = " "...原创 2012-07-18 19:44:07 · 802 阅读 · 0 评论 -
webbench对nginx+web.py的hello.py测试
1,访问效果[code="java"]curl http://127.0.0.1:8000/helloHello World!dcurl http://python.i-david.org/helloHello World!d[/code]2,基本部署启动脚本[code="java"]#!/bin/shps -aux | grep 8000 ...原创 2012-07-19 18:25:02 · 80 阅读 · 0 评论 -
Editplus配置python开发环境
1,环境介绍windows 7 64editplus v3.4.1python 2.7.3 2,在Editplus中添加插件 Tools-->Configure User Tools… 3,添加python执行环境 Tools-->User tools 4,配置 Output patte...原创 2012-07-21 07:38:24 · 121 阅读 · 0 评论 -
通过python获取外网IP
通过python获取外网IP[code="python"]#!/usr/bin/python# -*- coding:utf-8 -*-# filename:getLocalIp.pyimport re,urllib2class Getmyip: def getip(self): try: myip = self.vis...原创 2012-08-01 18:13:31 · 89 阅读 · 0 评论 -
nginx+uwsgi+python web发布
1,nginx,python web的环境已经配置好了,重点介绍uwsgi的使用2,python web程序[code="python"]david@david-server:~/python$ cat start.pyimport weburls = ( '/.*', 'index')class index: def GET(self)...原创 2012-08-22 10:25:46 · 63 阅读 · 0 评论 -
python 中文转拼音
1,源码[code="python"]#!/usr/bin/python# -*- coding:utf-8 -*-# filename:demo.pytable = 'a,-20319;ai,-20317;an,-20304;ang,-20295;ao,-20292;ba,-20283;bai,-20265;ban,-20257;bang,-20242;bao,-20...原创 2012-09-16 17:38:25 · 320 阅读 · 0 评论 -
git for eclipse
1,安装gitapt-get install git2,安装EGit插件http://download.eclipse.org/egit/updates3,配置ssh认证信息Windows-->Preferences-->General-->Network connection-->SSH2一般会自动设置4,创建项目,加入gitTeam--> Sha...原创 2012-11-11 21:17:10 · 86 阅读 · 0 评论