摘要:
<!DOCTYPE html><html><head><meta charset="utf-8"><title>文档标题</title><link rel="stylesheet" href="imooc.css" type="text/css"><script src="https://www.i 阅读全文
摘要:
<!DOCTYPE HTML><html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>window.open</title><script type="text/javascri 阅读全文
摘要:
<html><head><meta http-equiv="Content-type" content="text/html; charset=utf-8" /><script src="https://www.imooc.com/static/lib/jquery/1.9.1/jquery.js" 阅读全文
摘要:
<!DOCTYPE html><html><head> <meta http-equiv="Content-type" content="text/html; charset=utf-8" /> <title></title> <style> div { width: 100px; height: 阅读全文
摘要:
<!DOCTYPE html><html><head> <meta charset="utf-8"/> <title>第一个简单的jQuery程序</title> <style type="text/css"> div{ padding:8px 0px; font-size:12px; text-a 阅读全文
摘要:
<!DOCTYPE HTML><html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>获得星期</title><script type="text/javascript"> var 阅读全文
摘要:
<!DOCTYPE html><html> <head> <meta http-equiv="Content-type" content="text/html; charset=utf-8" /> <title></title> <style> .left div, .right div { wid 阅读全文
摘要:
<!DOCTYPE html><html> <head> <meta http-equiv="Content-type" content="text/html; charset=utf-8" /> <title></title> <style> .left div, .right div { wid 阅读全文
摘要:
<!DOCTYPE html><html> <head> <meta http-equiv="Content-type" content="text/html; charset=utf-8" /> <title></title> <script src="https://www.imooc.com/ 阅读全文
摘要:
import random a=random.randint(1,10) b=0 num=3 while num>0: print("你还有"+str(num)+"次机会") num-=1 b=int(input("请输入数字:")) if num==0 or b==a: print("你猜对了!" 阅读全文
摘要:
a=["blue","red","brack"] print(len(a))#列表长度 a.append("yellow") print(a) b=sorted(a)#排序,升序,不改变原列表 print(b) a.sort()#排序,升序,改变原列表 print(a) a.pop(3)#删除,根据 阅读全文
摘要:
转化int: 不转int: 1.matplotlib.pyplot as plt 画图库 2.plt.show() 查看图像 3.plt.plot(x,y,c,linewidth=10) x,y分别是图像坐标轴,linewidth设置折线图线的粗细,c设置线条颜色 4.plt.scatter(x,y 阅读全文
摘要:
代码: try: from urllib2 import urlopen except ImportError: from urllib.request import urlopen import json #导入json,读取json文件 from matplotlib import pyplot 阅读全文
摘要:
代码实现: import csv from matplotlib import pyplot as plt from datetime import datetime date=[] airmax=[] airmin=[] with open(r'C:\Users\Administrator\Des 阅读全文
摘要:
代码: import csv from matplotlib import pyplot as plt arr=[] arrmin=[] date=[] with open(r'C:\Users\Administrator\Desktop\新建文本文档 (3).csv') as cs: read=c 阅读全文
摘要:
randomwalk.py代码 from random import choice class RandomWalk(): def __init__(self,points=5000): self.points=points self.x=[0] self.y=[0] def random_walk 阅读全文
摘要:
方法和画折线图类似,差别在于画图函数不一样,用的是scatter() import matplotlib.pyplot as plt #以外部两个txt表分别作为x,y画图n=0m=0with open(r'C:\Users\Administrator\Desktop\test.txt') as t 阅读全文
摘要:
思路:用open打开文件,再用a=filename.readlines()提取每行的数据作为列表的值,然后传递列表给matplotlib并引入对应库画出图像 代码实现:import matplotlib.pyplot as pltn=0 #定义作为后面修改列表的索引with open(r'C:\Us 阅读全文
摘要:
<script src="https://cdn.staticfile.org/jquery/2.2.4/jquery.min.js"></script><!DOCTYPE html><html><head><meta charset="utf-8"><title>文档标题</title><scri 阅读全文