πŸ“Š Python
Q. What will be the output?
Code:
print('1' + '2' * 3)
  • (A) 123
  • (B) 1222
  • (C) 126
  • (D) Error
πŸ’¬ Discuss
βœ… Correct Answer: (B) 1222

Explanation: '2' * 3 becomes '222'; concatenated with '1' gives '1222'.

Explanation by: Mr. Dubey
'2' * 3 becomes '222'; concatenated with '1' gives '1222'.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
48
Total Visits
πŸ“½οΈ
8 mo ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
87%
Success Rate