【python笔记系列】元组的基本使用01

 时间:2026-04-23 07:37:49

1、打开python编辑器,本文使用pycharm

【python笔记系列】元组的基本使用01

2、点击新建一个py文件

【python笔记系列】元组的基本使用01

3、定义一个函数(为使用方便)

【python笔记系列】元组的基本使用01

4、输入t1 = (1,),定义第一个元组

【python笔记系列】元组的基本使用01

5、输入t2 = (1, 2),定义第二个元组

【python笔记系列】元组的基本使用01

6、输出t1的类型

【python笔记系列】元组的基本使用01

7、输出t2的类型

【python笔记系列】元组的基本使用01

  • 【python笔记系列】字典的基本使用02
  • 【python笔记系列】列表的基本使用04
  • 【python笔记系列】字典的基本使用024
  • Python中如何删除元组
  • Python中如何修改元组
  • 热门搜索
    stories怎么读 代驾公司怎么注册 苹果手机怎么换主题 横折弯钩怎么写 汽车电瓶没电了怎么办 皮肤过敏怎么办 怎么学好高一物理 电是怎么产生的 雌激素高怎么办 孕妇痔疮怎么办