发布

oeasy教您玩转linux、python

oeasy教您玩转linux、python
专栏成员
223
文章
113454
阅读量
24
订阅数
[oeasy]python070_如何导入模块_导入模块的作用_hello_dunder_双下划线
import jieba from wordcloud import WordCloud import matplotlib.pyplot as plt # 读取文件 with open('/usr/lib/python3.8/LICENSE.txt') as file: text = file.read() # 使用jieba进行中文分词 words = ' '.join(jieba.cut(text)) # 生成词云 wordcloud = WordCloud(font_path='/usr/share/fonts/truetype/wqy/wqy-microhei.ttc', # 指定中文字体路径 width=800, height=600, background_color='white').generate(words) # 使用matplotlib展示词云 plt.imshow(wordcloud, interpolation='bilinear') plt.axis('off') plt.show()
oeasy
2025-03-01
470
[oeasy]python069_当前作用域都有些什么_列表dir_函数_builtins
oeasy
2025-02-24
370
[oeasy]python068_异常处理之后做些什么_try语句的完全体_最终_finally
import traceback try: a except: print("in except---------") traceback.print_exc() print("in except=========")
oeasy
2025-02-21
300
[oeasy]python067_如何处理各种可能的异常_try_except_Error
067_如何处理各种可能的异常_try_except_Error0 播放 · 0 赞同视频
oeasy
2025-02-17
400
[oeasy]python065python报错怎么办_try_试着来_except_发现异常
a = input("How many apples do you have:") weight = a * 2 print("You have ",weight, "kg apples.")
oeasy
2025-02-11
420
[oeasy]python062_提示符是怎么来的_[词根溯源]prompt_input_输入函数_提示符
提示符是怎么来的_[词根溯源]prompt_input_输入函数_提示符 回忆上次内容
oeasy
2025-01-20
430
[oeasy]python061_如何接收输入_input函数_字符串_str_容器_ 输入输出
061_python如何接收输入_input函数_字符串_str_容器 输入输出0 播放 · 0 赞同视频
oeasy
2025-01-17
500
[oeasy]python059变量命名有什么规则_惯用法_蛇形命名法_name_convention_snake
local_soil_moisture_value_to_determine_the_amount_of_water_added = 0
oeasy
2025-01-13
660
[oeasy]python057_如何删除print函数_dunder_builtins_系统内建模块
057如何删除print函数_dunder_builtins_系统内建模块9 播放 · 0 赞同视频
oeasy
2025-01-06
480
[oeasy]python055_python编程_容易出现的问题_函数名的重新赋值_print_int
055_python编程_容易出现的问题_函数名的重新赋值_print_int0 播放 · 0 赞同视频
oeasy
2024-12-29
640
[oeasy]python054_python有哪些关键字_keyword_list_列表_reserved_words
oeasy
2024-12-20
460
[oeasy]python053_学编程为什么从hello_world_开始
[趣味拓展]为什么学编程都要从hello_world_开始_HelloWorld的由来_程序员的浪漫 回忆上次内容
oeasy
2024-12-18
610
[oeasy]python052_[系统开发语言为什么默认是c语言
[系统开发语言为什么默认是c语言 [趣味拓展]c语言发祥史_c是如何成为第一系统语言的
oeasy
2024-12-12
400
[oeasy]python051_什么样的变量名能用_标识符_identifier
oeasy
2024-12-11
910
[oeasy]python050_如何删除变量_del_delete_variable
类型和地址 print("type:", type(a)) print("id:", id(a))
oeasy
2024-12-09
570
[oeasy]python049_[词根溯源]locals_现在都定义了哪些变量
[词根溯源]locals_现在都定义了哪些变量_地址_pdb_调试中观察变量 回忆上次内容
oeasy
2024-12-07
640
[oeasy]python048_用变量赋值_连等赋值_解包赋值_unpack_assignment
变量赋值 s1 = "oeasy" s2 = s1 print(id(s1)) print(id(s2)) print(id(s1) == id(s2))
oeasy
2024-12-04
500
[oeasy]python047_变量在内存内的什么位置_物理地址_id_内存地址
相同对象 s1 = "oeasy" s2 = "oeasy" print(id(s1)) print(id(s2)) print(id(s1) == id(s2) )
oeasy
2024-12-02
520
046_pdb_debug_调试赋值语句_先声明赋值_再使用
oeasy
2024-11-28
590
044[词根溯源]declaration_变量含义_meaning_声明
oeasy
2024-11-24
1070
点击加载更多
社区活动
Python精品学习库
代码在线跑,知识轻松学
博客搬家 | 分享价值百万资源包
自行/邀约他人一键搬运博客,速成社区影响力并领取好礼
技术创作特训营·精选知识专栏
往期视频·干货材料·成员作品 最新动态
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档