随笔分类 -  Python小程序

摘要:1 import pandas as pd 2 import pymysql 3 4 5 # 参数设置 DictCursor使输出为字典模式 连接到本地用户ffzs 密码为666 6 config = dict(host='localhost', user='xxx', password='xxxx 阅读全文
posted @ 2020-03-14 15:12 Ian_learning 阅读(1558) 评论(0) 推荐(0)
该文被密码保护。
posted @ 2019-12-21 20:22 Ian_learning 阅读(1) 评论(0) 推荐(0)
摘要:使用范例: >money_computer.py -t future_each -y 30 -m 1460 -r 5In the 30.0 year, Future money is 97000.7173544Ex: years =2 . You cash is 1460.0 + (1460.0 * 阅读全文
posted @ 2019-09-24 21:40 Ian_learning 阅读(588) 评论(0) 推荐(0)
摘要:真实使用的时候 1.需要考虑判断添加layer的位置条件。 2.需要加入读取标准文件,可以方便一次性多加数个layer。 3. streamlayer,techdisplay等等其他的文件需要另外加入。 4.最好加入一个备份模块,防止出现意外情况; 5.加入使用说明; 6.display 文件是需要 阅读全文
posted @ 2018-07-15 17:27 Ian_learning 阅读(245) 评论(0) 推荐(0)
摘要:1 '''最好让k的值与list的元素数量n差不多,如果是n的幂的话就不合适了''' 2 3 4 def init_part(k,out_list): 5 #k is the max int of out_list.Value in out_list is larger than >= 0. 6 Assist_list = [] 7 Assist_lis... 阅读全文
posted @ 2018-04-10 17:45 Ian_learning 阅读(609) 评论(0) 推荐(0)
摘要:非常简单的算法。 阅读全文
posted @ 2018-04-09 21:06 Ian_learning 阅读(702) 评论(0) 推荐(0)
摘要:程序2:修改haproxy配置文件 需求: 1 1、查 2 输入:www.oldboy.org 3 获取当前backend下的所有记录 4 5 2、新建 6 输入: 7 arg = { 8 'bakend': 'www.oldboy.org', 9 'record':{ 10 'server': ' 阅读全文
posted @ 2017-11-25 12:48 Ian_learning 阅读(915) 评论(2) 推荐(1)
摘要:程序: 三级菜单 要求: 重复的代码比较多。但是目前学的好像只能这么用。注意最后几行代码,由于是第一层,不能退出,所以不一样。 阅读全文
posted @ 2017-11-05 20:38 Ian_learning 阅读(347) 评论(0) 推荐(0)
摘要:程序:购物车程序 需求: 阅读全文
posted @ 2017-10-31 10:50 Ian_learning 阅读(333) 评论(0) 推荐(0)
摘要:作业二:编写登陆接口 输入用户名密码 认证成功后显示欢迎信息 输错三次后锁定 http://www.cnblogs.com/alex3714/articles/5465198.html 自己写的第一个长一点的Python程序,当作纪念啦~ 要在e盘里面有四个文件才可以运行哦~ 1 #! /usr/b 阅读全文
posted @ 2017-10-23 20:55 Ian_learning 阅读(1693) 评论(4) 推荐(0)