Home
Head's Up: I'm in the middle of upgrading my site. Most things are in place, but there are something missing and/or broken including image alt text. Please bear with me while I'm getting things fixed.

Turn A Flat List Into A Dictionary In Python With zip

python
source = [
  "first_name", 
  "Alfa", 
  "middle_name", 
  "Bravo", 
  "last_name", 
  "Charlie"
]

new_dict = dict(zip(source[::2], source[1::2]))

print(new_dict)
results start