Answer:
def createPhonebook(firsts, lasts, numbers):
d = {}
for i in range(len(firsts)):
k = firsts[i] + " " + lasts[i]
d[k] = numbers[i]
return d
Step-by-step explanation:
Create a function named createPhonebook that takes three arguments, firsts, lasts, numbers
Initialize an empty dictionary, d
Create a for loop that iterates the length of the firsts times(Since all the arguments have same length, you may use any of them). Inside the loop, set the key as the item from firsts, a space, and item from lasts (If the name is "Ted" and last name is "Mosby", then the key will be "Ted Mosby"). Set the value of the key as the corresponding item in the numbers list.
When the loop is done, return the d