python 内置高級函數盤點
摘要:1. map(function, iterable, ...) map()函数接受一个函数和一个可迭代对象作为参数,将函数应用于可迭代对象的每个元素,并返回一个包含结果的迭代器 # 将列表中的每个元素加1 numbers = [1, 2, 3, 4, 5] result = map(lambda x
阅读全文
posted @ 2024-07-12 16:52
果然,我没有抓住重点
posted @ 2024-07-12 16:52
posted @ 2024-05-06 16:34
posted @ 2024-05-06 16:29
posted @ 2023-01-02 22:54
posted @ 2022-12-31 15:37