Python笔记
1、各种库
2、折线图——可运行
import matplotlib.pyplot as plt
input_values = [1, 2, 3, 4, 5]
squares = [1, 4, 9, 16, 25]
plt.plot(input_values, squares, linewidth=5)
plt.title("Square Numbers", fontsize=24)
plt.xlabel("Value", fontsize=14)
plt.ylabel("Square of Value", fontsize=14)
plt.tick_params(axis='both', labelsize=12)
plt.show()
3、
import matplotlib.pyplot as plt
from matplotlib import pyplot
python 3
1. [ ] Python 3.8.0
2. [ ] PyCharm 2019.3.1 (Community Edition)
1、pip下载速度慢的问题:
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple XXX
例如pip安装PyQt5库:pip install -i https://pypi.tuna.tsinghua.edu.cn/simple PyQt5
2、PyCharm external tools设置:
QTDesigner:按以下配置可以右键.ui文件选择QTDesigner,直接在QTDesigner中打开.ui文件。
> Program 选择 designer.exe的位置
> Arguments 选择 $FileName$
> Workingdirectory 选择 $FileDir$
PyUIC:按以下配置可以右键.ui文件选择PyUIC,直接在同位置生成.py文件。
> Program 选择 pyuic5.exe的位置
> Arguments 选择 $FileDir$\$FileName$ -o $FileNameWithoutExtension$.py(每个人设置可能不一样)
> Workingdirectory 选择 $ProjectFileDir$
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 全程不用写代码,我用AI程序员写了一个飞机大战
· DeepSeek 开源周回顾「GitHub 热点速览」
· 记一次.NET内存居高不下排查解决与启示
· 物流快递公司核心技术能力-地址解析分单基础技术分享
· .NET 10首个预览版发布:重大改进与新特性概览!