Pair Two Lists
Completed
Read a line of names and a line of scores (same length). Print each as name: score.
Input
Two lines.
Output
One line per pair.
Example
Input
ann bob cy 90 72 85
Output
ann: 90 bob: 72 cy: 85
Editor
Python
Hints
zip(a, b) walks through two lists in step.
Solution explanation
zip stops at the shorter list. dict(zip(names, scores)) builds a dictionary.
Show solution
names = input().split()
scores = input().split()
for name, score in zip(names, scores):
print(f"{name}: {score}")