摘要: from random import random from time import perf_counter import time from tqdm import tqdm scale = 50 print("执行开始".center(scale//2, "-")) start = time. 阅读全文
posted @ 2020-12-14 19:18 gsy1121 阅读(93) 评论(0) 推荐(0)
摘要: import numpy as np ls1 = [10, 42, 0, -17, 30] nd1 =np.array(ls1) print(nd1) print(type(nd1)) import scipy import numpy as np from scipy import linalg 阅读全文
posted @ 2020-12-14 19:17 gsy1121 阅读(71) 评论(0) 推荐(0)
摘要: from random import random def printInfo(): # 打印程序介绍信息 print('这个程序模拟两个选手A和B的某种竞技比赛') print('程序运行需要A和B的能力值(以0到1之间的小数表示)') def getInputs(): # 获得程序运行参数 a 阅读全文
posted @ 2020-12-14 19:09 gsy1121 阅读(55) 评论(0) 推荐(0)
摘要: html = '''<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>菜鸟教程(runoob.com)</title> </head> <body> <h1>我的第一个标题</h1> <p id="first">我的第一个段落。< 阅读全文
posted @ 2020-12-14 14:14 gsy1121 阅读(63) 评论(0) 推荐(0)
摘要: import urllib.request url = "https://www.sogou.com/" response = urllib.request.urlopen(url) content = response.read().decode('utf-8') print(content) 阅读全文
posted @ 2020-12-13 22:51 gsy1121 阅读(77) 评论(0) 推荐(0)
摘要: import jieba excludes = {"什么","一个","我们","那里","你们","如今","说道","知道","起来","姑娘","这里","出来","他们","众人","自己", "一面","只见","怎么",&quo 阅读全文
posted @ 2020-11-14 23:45 gsy1121 阅读(40) 评论(0) 推荐(0)
摘要: import turtle as t t.setup(600, 600, None,None) t.pu() t.fd(-120) t.pensize(5) t.width(5) t.pencolor("darkgreen") t.pd() t.fd(250) t.seth(120) t.penco 阅读全文
posted @ 2020-09-15 16:53 gsy1121 阅读(103) 评论(0) 推荐(0)
摘要: import turtle as t t.setup(650,350,200,200) t.pu() t.fd(50) t.left(-90) t.fd(100) t.right(90) t.pd() t.pensize(5) t.pencolor("black") for i in range(6 阅读全文
posted @ 2020-09-15 16:43 gsy1121 阅读(43) 评论(0) 推荐(0)
摘要: import turtle as t iimport turtle as t t.fillcolor("red")#颜色填充函数 t. begin_fill() while True: t.forward(200) t.right(144) if abs(t.pos())<1:#看画笔是否回到原点, 阅读全文
posted @ 2020-09-14 19:51 gsy1121 阅读(72) 评论(0) 推荐(0)