首页 软件开发 代码片段 python ( Page 77 )

python 1073

#Python
Python sql server和postgresql的表结构转换

#coding=utf-8 #import _mssql import psycopg2,pymssql import types TableSpace='ABS.' class …

2015-01-08 297

#Python
Python 计算已经过去多少个周末

计算已经过去多少个周末。 def weekends_between(d1,d2): days_between = (d2-d1).days weekends, leftover =…

2015-01-08 1,000

#Python
python抓取图片示例

#!/usr/bin/python # -*- coding:utf-8 -*- import re import os import urllib, urllib2, cooki…

2015-01-08 413

#Python
Python 实现简单的矩阵

#!/usr/bin/python # -*- coding: utf-8 -*- ''''' Created on 2015-1-7 @author: beyondzhou @n…

2015-01-07 924

#Python
python密码生成器

python密码生成器,,,,,,,,,,,,,,,,, from random import randrange, sample #定义列表 password_list = ['…

2015-01-06 505

#Python
文艺一把!Python爬取读者制作PDF!

#!/usr/bin/env python #coding=utf-8 """ Author: Anemone Filename: getmain.py Last modified…

2015-01-06 245

#Python
python中英文混合字符串对齐输出

#!/usr/bin/env python # -*- coding: utf-8 -*- def is_chinese(uchar): """判断一个unicode是否是汉字""…

2015-01-06 282

#Python
深度搜索解数独

def guess(ku, i, v, b = 1): affects = [] for j in range(b, 81): if (i / 9 == j / 9 \ or i …

2015-01-06 262

#Python
文件去重

__author__ = 'lixin' import os from shutil import * from hashlib import md5 import datetim…

2015-01-06 266

#Python
Python实现简单的缓存和缓存decorator

一个简单的缓存实现,将缓存数据保存在单例的对象中。 使用方法: # Initialize SimpleCache({'data':{'example':'example data'…

2015-01-06 554

#Python
python解析网页的字符编码

import urllib.request import re content = urllib.request.urlopen("http://www.open-ope…

2015-01-06 329

#Python
Python使用win32api获取DLL和EXE文件版本号

import win32api def getFileVersion(file_name): info = win32api.GetFileVersionInfo(file_nam…

2015-01-06 306
1 75 76 77 78 79 90