Python reduce()

Jmnote bot (토론 | 기여)님의 2020년 11월 2일 (월) 02:31 판 (봇: 자동으로 텍스트 교체 (-source +syntaxhighlight))

1 개요

Python reduce()
from functools import reduce
a = [2, 3, 4, 5]
print( reduce((lambda x, y: x*y), a) )
# 120

2 같이 보기

3 참고

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}