Sail E0 Webinar
Question
What is the output of the following piece of code when executed in Python shell?a=("Check")*3 a
Options:
A .  ('Check','Check','Check')
B .  * Operator not valid for tuples
C .  ('CheckCheckCheck')
D .  Syntax error
Answer: Option C


Here ("Check) is a string not a tuple because there is no comma after the element.



Was this answer helpful ?

Submit Solution

Your email address will not be published. Required fields are marked *

Latest Videos

Latest Test Papers