Tuple in Python MCQs Exercise I

Ques 1 Tuple


Tuple is a........

A Mutable Datatype.
B Immutable Datatype.
C Both (a) and (b)
D None of the above.

Ques 2 Tuple


What is the output of the following Python Code?


tu=("Vikas" , "SmallCode" , 12) tu[0]="Vicky" print(tu[0])

A Error
B ("Vicky" , "SmallCode" , 12)
C ("Vikas" , "SmallCode" , 12)
D None of the above.

Ques 3 Tuple


What is the output of the following Python Code?


tu=("Vikas" , "SmallCode" , 12)
tu=list(tu)
tu[0]="Vicky"
tu=tuple(tu)
print(tu)

A Error
B ("Vicky" , "SmallCode" , 12)
C ("Vikas" , "SmallCode" , 12)
D None of the above.

Ques 4 Tuple


What is the output of the following Python Code?


tu=(1,2,3,4,5,6,7,8)
p=[1:-1]
p[0]="Vicky"
print(tu)

A Error
B (2,3,4,5,6,7)
C (2,3,4,5,6,7,8)
D (1,2,3,4,5,6,7,8)