python
cdan134
这个作者很懒,什么都没留下…
展开
-
【1】python初步设置
安装python(3.5.1)+pycharm之后设置配色终端运行helloworld新建工程文件在工程文件中:注释+输出helloworld原创 2016-09-23 11:58:08 · 252 阅读 · 0 评论 -
【15】python 列表补充+orientdb更新属性值
def supplement_list(list,supplementList,supplementListPos): """ 补充列表:将需要补充的信息按位置补充完成 定义声明位置数值(temp_list_pos)的数值和长度(数值为50+长度和全列表长度相同) 两个列表对应比较(全列表+补充列表) 全列表和补充列表中都存在一个数值,位置数值(t原创 2016-10-31 15:52:44 · 566 阅读 · 0 评论 -
【13】python列表去重/寻找一个文件夹中的所有文件/函数返回多个值
1,去重思路:遍历列表,将不予列表该指针前面的数值相同的数值复制给新的列表 a = [1,2,3,3,4,5,5,5,5,5,6,7] b = [] # temp = 1 for i in range(len(a)): for j in range(i): if a[i] == a[j]:原创 2016-10-19 22:43:11 · 436 阅读 · 0 评论 -
【12】配置环境变量
软件的环境变量配置原创 2016-10-08 13:58:11 · 193 阅读 · 0 评论 -
【11】pip upgrade 8.1.2
easy_install-3.5 pip ==8.1.2完成升级原创 2016-10-11 00:37:49 · 367 阅读 · 0 评论 -
【10】python 读写word文档
对应链接 https://python-docx.readthedocs.io/en/latest/from docx import Documentfrom docx.shared import Inchesfrom io import StringIOdocument = Document()document.add_heading('Document Titl原创 2016-10-11 00:57:56 · 3564 阅读 · 0 评论 -
【9】安装python和pycharm软件
1,先下载python软件https://www.python.org/我在这里下载的是win,你可以下载其他的。下载之后直接安装即可2,下载python运行服务平台pycharm,我下载的是专业版https://www.jetbrains.com/pycharm/download/#section=windows安装pycharm,pycharm使原创 2016-10-18 23:12:10 · 417 阅读 · 0 评论 -
【8】设置python的软件内容设置
快捷键的设置长按【Ctrl】+[左键]---->查找方式定义长按【Alt】+[Up]/[Down]-->所有方式的开头【Ctrl】+Q-->查看方式中属性的类型【Ctrl】+B-->查看模块中定义的方式原创 2016-10-18 22:33:55 · 166 阅读 · 0 评论 -
【16】python使用turtle库绘画
import turtledef drawSnake(rad, angle, len, neckrad): # for i in range(len): turtle.circle(rad, angle) # 画圆 rad:圆半径 angle:圆弧度 turtle.circle(-rad, angle) turtle.circle(rad,原创 2016-11-05 22:16:38 · 18126 阅读 · 0 评论 -
【7】编译python时出现的错误
1,No edge has been created because no target vertices原创 2016-10-16 22:36:36 · 266 阅读 · 0 评论 -
【6】python将字符串转换成变量(不可赋值)
第一种形式a = 'b'mystr = ''.join(a)print(mystr)原创 2016-10-13 23:57:26 · 1801 阅读 · 0 评论 -
【5】python读取excel表格(from openpyxl import load_workbook)
from openpyxl import load_workbookINPUT_FILES_BASE_PATH = "E:\\project soft\\pycharm\\practice\\untitled\\"EXCEL_FILENAME = '2013.全年-des.xlsx'def get_excelTitleList(): templist = [] title原创 2016-10-13 23:14:20 · 19610 阅读 · 0 评论 -
【4】python将翻译中文成英文,以字符串形式输出,然后改变字符串形式
def translationChtoEn(list): import urllib.request import urllib.parse import json while True: content = list if content == 'Q': break else:原创 2016-10-13 23:01:31 · 7485 阅读 · 1 评论 -
【3】python有道调用API进行翻译
def translationChtoEn(list): import urllib.request import urllib.parse import json while True: content = list if content == 'Q': break else:原创 2016-10-13 22:26:05 · 2266 阅读 · 0 评论 -
【14】python和orientab连接,导入entity的实例
1,python和orientab连接,在插入了新的实例之后,可以直接再次插入不同属性的数据#!user/bin/env/python# coding: utf-8import pyorientclient = pyorient.OrientDB("localhost", 2424)session_id = client.connect( "root", "123456原创 2016-10-21 11:59:21 · 1097 阅读 · 2 评论 -
【2】python-字符串+条件语句+逻辑语句+转义字符
原创 2016-09-23 12:34:23 · 281 阅读 · 0 评论 -
unicode+utf-8+acsii和encode的去比啊
原创 2017-01-02 22:58:55 · 297 阅读 · 0 评论