নিচের Python কোডটি চালালে output কী হবে?

print(", ".join(["Sylhet", "social", "jackfruit"]))
  1. ক) Sylhet social jackfruit
  2. খ) social, jackfruit
  3. গ) Sylhet, social, jackfruit
  4. ঘ) Sylhet, , social, , jackfruit
উত্তর দেখুন
সঠিক উত্তর: গ) Sylhet, social, jackfruit

কোডটি চালালে output হয়: Sylhet, social, jackfruit। join() তালিকার স্ট্রিংগুলো মাঝে বিভাজক বসিয়ে জোড়ে - শুরু বা শেষে বিভাজক বসে না।

সূত্র: কোডটি চালিয়ে যাচাই করা (সোশ্যাল বাংলা)
এই বিষয়ে রিলস কুইজ