2020年4月12日

摘要: <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> </head> <body> <input type = "text" id="clock" style="width: 449px 阅读全文
posted @ 2020-04-12 16:19 三道_python 阅读(171) 评论(0) 推荐(0) 编辑

2020年3月3日

摘要: import pymysql conn = pymysql.connect(host='127.0.0.1', port=3306, user='root', passwd='', db='work') cursor = conn.cursor()#创建游标 #增加单个 # r = cursor.e 阅读全文
posted @ 2020-03-03 06:30 三道_python 阅读(189) 评论(0) 推荐(0) 编辑

2020年2月29日

摘要: 非常感谢老师! 看图吧 班级表 创建及添加数据 在此省略... 创建student表 create table student( sid int not null auto_increment primary key, sname varchar(30), gender enum('男','女') 阅读全文
posted @ 2020-02-29 11:33 三道_python 阅读(1004) 评论(0) 推荐(0) 编辑

2020年2月4日

摘要: ———————— ————data #保存class类及类中的对象 ————int #执行程序 ———————————— #@Time:2020/2/4 16:48 #@Author :jok #@file :data.py #@software:PyCharm class web: def hom 阅读全文
posted @ 2020-02-04 17:04 三道_python 阅读(199) 评论(0) 推荐(0) 编辑

2020年2月2日

摘要: 一下文件执行将产生乱码,切.log文件显示问好,打不开 import logging def shop_logging(name): name = name+"登录成功!" logger = logging.getLogger() fh = logging.FileHandler("test.log 阅读全文
posted @ 2020-02-02 18:31 三道_python 阅读(4145) 评论(0) 推荐(2) 编辑

2020年2月1日

摘要: #模块用来组织函数的 #包是用来组织模块的 #判断是否为包,主要是看是否有_init_.py #bin与bao有什么关系 #调用模块或者包的方法一览 # import time,sys 系统模块可以直接调用,用“,”分割 # import calculte 调用同文件夹的模块,使用方法calcult 阅读全文
posted @ 2020-02-01 11:19 三道_python 阅读(1357) 评论(0) 推荐(0) 编辑

2020年1月30日

摘要: 弄了6个小时,各种出错,伪静态规则出错1次, def逻辑思维出错1次。哈哈 # 实现加减乘除及拓号优先级解析 # 用户输入 1 - 2 * ( (60-30 +(-40/5) * (9-2*5/3 + 7 /3*99/4*2998 +10 * 568/14 )) - (-4*3)/ (16-3*2) 阅读全文
posted @ 2020-01-30 16:06 三道_python 阅读(221) 评论(0) 推荐(0) 编辑

2020年1月29日

摘要: import re #正则表达式是用来干什么的?匹配字符串 #首先回顾一下字符串的使用方法。 # s = "hello world" # print(s.find("e")) #查找 # ret = s.replace("ll","xx") # print(ret) # print(s.split( 阅读全文
posted @ 2020-01-29 20:08 三道_python 阅读(216) 评论(0) 推荐(0) 编辑

2020年1月28日

摘要: #课程回忆day 17 生成器,迭代器,yield send iter next#列表生成式print([x*2+6 for x in range(10)])#生成器(generator Object)# next send 方法#创建生成器两种方式:# 1.(x*2+6 for x in rang 阅读全文
posted @ 2020-01-28 16:10 三道_python 阅读(179) 评论(0) 推荐(0) 编辑
 
摘要: import random print(random.random()) #0.1-1 print(random.randint(1,8)) #1-8 print(random.choice("helloworld")) #h e l l o w o r l d 打散字符串,随机输出一个。 prin 阅读全文
posted @ 2020-01-28 15:36 三道_python 阅读(3317) 评论(0) 推荐(0) 编辑