随笔分类 -  python自动化运维

摘要:pygame安装:pip install -i http://pypi.douban.com/simple pygame pygame字典:http://www.pygame.org/docs/ref/display.html 导入pygame import pygame 创建窗口 import p 阅读全文
posted @ 2020-03-13 09:26 什么都不会的小郭 阅读(121) 评论(0) 推荐(0) 编辑
摘要:一、等边三角形方法 import turtle import time t = turtle.Turtle() def sanjiao(lenght,color): t.fillcolor(color) t.begin_fill() jiaodu = [240,120,120] for i in j 阅读全文
posted @ 2020-02-27 15:33 什么都不会的小郭 阅读(226) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2020-02-10 11:24 什么都不会的小郭 阅读(551) 评论(0) 推荐(0) 编辑
摘要:easygui安装: pip install -i https://pypi.tuna.tsinghua.edu.cn/simple easygui 导入easygui模块: import easygui msgbox方法: import easygui name = easygui.msgbox( 阅读全文
posted @ 2020-02-05 10:10 什么都不会的小郭 阅读(1063) 评论(0) 推荐(0) 编辑
摘要:#!/usr/bin/env python # -*- coding: UTF-8 -*- import os import socket import psutil import datetime import time import re import subprocess import yagmail def net_info(): p = os.popen("hostname -I") p 阅读全文
posted @ 2020-01-06 15:23 什么都不会的小郭 阅读(216) 评论(0) 推荐(0) 编辑
摘要:输⼊⼀个字符串,要求判断在这个字符串中⼤写字⺟,⼩写字⺟,数字, 其它字符共出现了多少次,并输出 阅读全文
posted @ 2020-01-02 10:17 什么都不会的小郭 阅读(496) 评论(0) 推荐(0) 编辑
摘要:一、文件内容差异对比方法:使用difflib自带模块,无需安装 输出结果符号含义 升级版:输出为html格式 vim diff.py #!/usr/bin/env pythonimport difflibtest1 = """ my name is Guo Hdong"""test1_lines = 阅读全文
posted @ 2019-06-27 14:24 什么都不会的小郭 阅读(312) 评论(0) 推荐(0) 编辑
摘要:#安装IPy模块#pip install IPy#from IPy import IPip_s = input('please input an IP or net-range:')#192.168.1.100ips = IP(ip_s)if len(ips) > 1: print('net: %s' %ips.net()) #输出网络地址 print('netmask: %s' %... 阅读全文
posted @ 2019-06-27 10:01 什么都不会的小郭 阅读(740) 评论(0) 推荐(0) 编辑
摘要:内存总数17.179869184G内存剩余8.441253888Gsswap(total=0, used=0, free=0, percent=0, sin=19010850816, sout=0)7659.97scputimes(user=7659.97, nice=0.0, system=326 阅读全文
posted @ 2019-06-26 17:12 什么都不会的小郭 阅读(379) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示