摘要: 第一阶段 第六章 6.10 数据容器(序列) str = "万过薪月,员序程马黑来,nohtyp学" new_str = str[::-1] obj_str = new_str[9:14]resout1 = str[::-1][9:14] print(obj_str) str = "万过薪月,员序程 阅读全文
posted @ 2023-06-15 16:31 ``飘`` 阅读(18) 评论(0) 推荐(0)
摘要: 第一阶段 第六章 6.7元组 text1 = ('周杰伦', 11, ['football', 'music']) index = text1.index(11) print(index) print(text1[0]) del text1[2][1] print(text1) text1[2].a 阅读全文
posted @ 2023-06-14 17:20 ``飘`` 阅读(10) 评论(0) 推荐(0)
摘要: 第一阶段 第六章 6.1 数据容器 6.2 列表 列表中元素类型不限, 可以混合 ["itheima", 888, True] 1 #列表里面嵌套列表 2 my_list= [[1, 2, 3], [4, 5, 6]] 3 print(my_list) 4 print(type(my_list)) 阅读全文
posted @ 2023-05-30 17:54 ``飘`` 阅读(17) 评论(0) 推荐(0)
摘要: 第一阶段 第五章 函数 5.1 简介 组织好的,可重复使用,有特定功能的封装起来的 str1 = "itheima" def my_len(data): count = 0 for i in data: count += 1 print(count) my_len(str1) 5.2 定义 5.3 阅读全文
posted @ 2023-05-29 16:20 ``飘`` 阅读(20) 评论(0) 推荐(0)
摘要: 上篇案例 #我写的 import random num = random.randint(1, 10) print(num) a = int(input("请输入数字")) if a == num: print("bingo!") elif a > num: b = int(input("大了,还有 阅读全文
posted @ 2023-05-26 21:38 ``飘`` 阅读(23) 评论(0) 推荐(0)
摘要: 上篇作业 name = "传智播客" stock_price = 19.99 stock_code = "003032" stock_price_daily_growth_factor = 1.2 growth_days = 7 finally_stock_price = stock_price * 阅读全文
posted @ 2023-05-25 16:30 ``飘`` 阅读(43) 评论(0) 推荐(0)
摘要: 第一阶段 第一章 pycharm 快捷键 第二章 1.1 字面量 被写下来的固定的值 6666 13.14 “Hello World!” 字符串 书写时 必须加 “双引号” 1.2 注释 ”# “单行注释 加空格是准售规范 “”“ 三个双引号:多行注释,支持换黄 ”“” 快捷键 ctrl + / 1 阅读全文
posted @ 2023-05-24 16:38 ``飘`` 阅读(12) 评论(0) 推荐(0)
摘要: markdowm 标题 标题: '#'+' '+'标题名字' 三级标题 字体 Hello,World! ** **加粗 ~~ ~~划线 引用 引用方法 '>'+' ' 分割线 ‘ ’ or ‘***’ 图片 超链接 点击跳转到我的博客园 这里按 ctrl 点击 列表 这里输入1.+‘ ’ B C 这 阅读全文
posted @ 2021-07-14 08:14 ``飘`` 阅读(25) 评论(0) 推荐(0)