πŸ“Š Python
Q. What is the output of the following program?
Code:
data = [2, 3, 9]
temp = [[x for x in[data]] for x in range(3)]
print (temp)
  • (A) [[[2, 3, 9]], [[2, 3, 9]], [[2, 3, 9]]]
  • (B) [[2, 3, 9], [2, 3, 9], [2, 3, 9]]
  • (C) [[[2, 3, 9]], [[2, 3, 9]]]
  • (D) None of these
πŸ’¬ Discuss
βœ… Correct Answer: (A) [[[2, 3, 9]], [[2, 3, 9]], [[2, 3, 9]]]

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
202
Total Visits
πŸ“½οΈ
4 y ago
Published
πŸŽ–οΈ
Shivam
Publisher
πŸ“ˆ
88%
Success Rate