Correct Answer: [1] [1, 2] [1, 2, 3]
Explanation:
Note: This Question is unanswered, help us to find answer for this one
Python Skill Assessment
Your Skill Level: Poor
Retake Quizzes to improve it
More Python MCQ Questions
What method is usually used to return unicode representation of an object?
def fn(a, *b, **c): print(c) fn(5) What will be the output?
What will typing the following at the Python interpreter produce? lang = list('Python') ; lang[:-4]
Which datatypes are immutable in Python
Which of these will allow you to put more than one statement in one line of text?
Upon creation of the 'dumbdbm' database, files with which of the given extensions are created?
Output of the following Python code? value = [2, 3, 4, 5, 6] cd = 0 try: cd = value[3] except IndexError: print('0', end = '') except: print('1', end = '') finally: print('0', end = '') cd = 10 try: cd = cd/0 except ZeroDivisionError: print('1', end = '') finally: print('0')
Output of the following Python code. def req(str): p=2 str = str.split() str2 = [] for i in str: if i not in str2: str2.append(i) for i in range(0, len(str2)): p=str.count(str2[i])+p print(p) def main(): str =str ='apple mango apple orange orange apple guava mango mango' req(str) if __name__=='__main__': main()'>
Output of the following Python code? lis = [11, 22, 33] lis1 = [14, 5, 6] lis2= lis + lis1 print (end='') for i in range(0,len(lis2)): print (lis2[i]*1, end=' ') print ("\r") lis3 = lis * 2 print (end='') for i in range(0,len(lis3)): print (lis3[i]+1, end=' ')
Correct answer from the given options. class St: stm = stm = 'B' def __init__(self, n, r): self.n = n self.r = r a = St('D', 3) print (a.stm) St.stm = 'D' b = St('A', 4) print (a.stm) print (b.stm)