转自:http://www.cnblogs.com/way_testlife/archive/2011/04/17/2019013.htmlPIL 下载:http://www.pythonware.com/products/pil/index.htm安装 PIL $ tar xvfz Imaging...
分类:
编程语言 时间:
2014-06-25 12:33:09
阅读次数:
305
Given a linked list and a value x, partition it such that all nodes less than x come before nodes greater than or equal to x.You should preserve the o...
分类:
其他好文 时间:
2014-06-25 12:14:23
阅读次数:
159
Given a digit string, return all possible letter combinations that the number could represent.A mapping of digit to letters (just like on the telephon...
分类:
其他好文 时间:
2014-06-25 12:09:43
阅读次数:
184
Objective-C is a class-based object system. Each object is an instance of some class; the object'sisapointer points to its class. That class describ.....
分类:
其他好文 时间:
2014-06-25 11:48:57
阅读次数:
162
团队已经决定逐步由java转向scala。现在的项目已经使用了几种编程语言。Java为主,ruby做代码生成器,python做安装脚本和命令行工具。其实从ruby和python的使用经验中,已经或多或少地接触到了FP的概念。Scala旗帜鲜明地在Java上增加了FP的功能,观念的冲突和复杂的语法让其...
分类:
其他好文 时间:
2014-06-25 11:36:19
阅读次数:
323
当前linux发行版python版本默认基本上都是2.7的,如果系统中有了python3.0以后的,或者自己安装了python3.3,但是用pip或者easy_install安装python3的module并不很方面,使用virtualenv就方便多了,安装pypy环境较好的办法也是用virtu.....
分类:
其他好文 时间:
2014-06-25 11:22:42
阅读次数:
305
题目链接You are given a string, S, and a list of words, L, that are all of the same length. Find all starting indices of substring(s) in S that is a conca...
分类:
其他好文 时间:
2014-06-25 09:42:27
阅读次数:
230
def upload(url,params):
'''
上传文件到服务器,不适合大文件
@params url 你懂的
@params {"action":"xxx","@file","file_path"} 普通参数 key:value 文件key头部加@
'''
import os
import urllib2
BOUNDAR...
分类:
编程语言 时间:
2014-06-25 06:50:59
阅读次数:
298
向python进军。。。。。。运行所需环境:python,MySQLdb贴下自己写的关于sql备份的python脚本:#!/usr/bin/envpythonimportMySQLdbimportosimporttimedataList=[]remoteAddr=‘xxxx‘user=‘root‘password=‘xxxx‘dbConnect=MySQLdb.connect(%s,%s,%s)%(remoteAddr,user,password)cu..
分类:
数据库 时间:
2014-06-25 06:24:30
阅读次数:
265
例子:实现目标,用Python编写用户登录验证脚本。知识点:1、while和if控制流2、运算表达式验证过程:脚本:#!/usr/bin/envpython#filename:Userloginauthentication#importsysname=‘Tiger‘passwd=‘123456‘counter=0times=3whileTrue:#-----------无限循环username=raw_input(‘..
分类:
编程语言 时间:
2014-06-25 06:19:51
阅读次数:
272