Python 딕셔너리 리스트 컬럼 추출하여 리스트 만들기

Jmnote (토론 | 기여)님의 2020년 7월 11일 (토) 19:06 판 (새 문서: ==개요== ;Python 딕셔너리 리스트 컬럼 join ;Python 딕셔너리 리스트 컬럼 추출하여 리스트로 <source lang='python' run> members = [ {'id': 102, 'name': "Ash...)
(차이) ← 이전 판 | 최신판 (차이) | 다음 판 → (차이)

1 개요

Python 딕셔너리 리스트 컬럼 join
Python 딕셔너리 리스트 컬럼 추출하여 리스트로
members = [
	{'id': 102, 'name': "Ashley Allen", 'address': "Seoul"},
	{'id': 202, 'name': "Peter Parker", 'address': "New York"},
	{'id': 104, 'name': "John Smith", 'address': "Tokyo"},
]
print(list(m['address'] for m in members))

2 같이 보기

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