Ask Question

Given the following code,

a = ['m', 'r', 'y']

b = ['e', 'r', '!']

ab = zip (a, b)

Which of the following statements will assign list a to x and list b to y?

+2
Answers (1)
  1. 20 April, 07:53
    0
    x = a

    y = b

    Explanation:

    list a is ['m', 'r', 'y']x = a

    to assign list to another variable, need to initialise new variable and assign that variable to list a

    where a = ['m', 'r', 'y']

    now x = ['m', 'r', 'y']

    Similarly,

    b = ['e', 'r', '!']

    y = b

    y = ['e', 'r', '!']
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “Given the following code, a = ['m', 'r', 'y'] b = ['e', 'r', '!'] ab = zip (a, b) Which of the following statements will assign list a to x ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers