파이썬 column()

Jmnote (토론 | 기여)님의 2020년 7월 11일 (토) 19:21 판 (→‎참고)
(차이) ← 이전 판 | 최신판 (차이) | 다음 판 → (차이)

1 개요[ | ]

Python column()
파이썬 column()
Python
CPU
0.0s
MEM
8M
0.0s
Copy
orders = [
  {'id': 1, 'name': 'Ashley', 'date': '2020-05-20'},
  {'id': 2, 'name': 'Peter' , 'date': '2020-05-20'},
  {'id': 3, 'name': 'Ashley', 'date': '2020-05-05'},
  {'id': 4, 'name': 'John'  , 'date': '2020-05-05'},
  {'id': 5, 'name': 'Peter' , 'date': '2020-05-05'},
]
names = [x['name'] for x in orders]
print( names )
['Ashley', 'Peter', 'Ashley', 'John', 'Peter']

2 같이 보기[ | ]

3 참고[ | ]