Skip to content
Related Articles

Related Articles

Python | Functions | Question 2
  • Last Updated : 05 Nov, 2020

What is the output of the following code :




L = ['a','b','c','d']
print("".join(L))

(A) Error
(B) None
(C) abcd
(D) [‘a’,’b’,’c’,’d’]


Answer: (C)

Explanation: “” depicts a null string and the join function combines the elements of the list into a string.

Quiz of this Question

Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready.

My Personal Notes arrow_drop_up
Recommended Articles
Page :