Search snippets
Browse Code Answers
FAQ
Usage docs
Log In
Sign Up
Home
TypeScript
how to make a dictionary of indices and lists python
user52346
Programming language:
TypeScript
2021-03-13 17:06:16
0
Q:
how to make a dictionary of indices and lists python
Krebto
Code:
TypeScript
2021-09-19 14:17:10
>>> lst = ['A','B','C'] >>> {k: v for v, k in enumerate(lst)} {'A': 0, 'C': 2, 'B': 1}
0
Tags
indice
python
list
make
how
dict
New to Communities?
Join the community