Skip to content

Latest commit

 

History

History
12 lines (9 loc) · 384 Bytes

File metadata and controls

12 lines (9 loc) · 384 Bytes

Python100

把Python知识点整理成100道习题,知识点来自两本书:Python基础教程(第3版)和流畅的Python,以后会定期加入更多的习题,大家帮忙点个赞哈,点赞越多,更新越快~

怎么查找列表中某个元素第一次出现的索引,从 0 开始

用 index 方法

>>> l = ['are', 'you', 'ok']
>>> l.index('you')
1