ExamVeda
Login
Home
31
What will be the output of the following Python code?
>>>t1 = (1, 2, 4, 3)
>>>t2 = (1, 2, 3, 4)
>>>t1 < t2
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
32
What is the data type of (1)?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
33
What will be the output of the following Python code?
>>>t=(1,2,4,3)
>>>t[1:-1]
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
34
Is the following Python code valid?
>>> a=(1,2,3)
>>> b=('A','B','C')
>>> c=tuple(zip(a,b))
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
35
What will be the output of the following Python code?
>>> a=("Check")*3
>>> a
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
36
Is the following Python code valid?
>>> a=(1,2,3,4)
>>> del a
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
37
Suppose t = (1, 2, 4, 3), which of the following is incorrect?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
38
What will be the output of the following Python code?
>>> a=[(2,4),(1,2),(3,9)]
>>> a.sort()
>>> a
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
39
What type of data is: a=[(1,1),(2,4),(3,9)]?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
40
What will be the output of the following Python code?
>>> import collections
>>> a=collections.namedtuple('a',['i','j'])
>>> obj=a(i=4,j=7)
>>> obj
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board