MCQ 11 MarkWhat is the output of the below program? A3B4✓4 is maximumDNone of the mentionedAnswerCorrect option: C. 4 is maximumcView full question & answer→
MCQ 21 MarkWhat will be the output? >>>test=”Hello World ” >>>test[6]='t' >>>print(test)AHelloBHello torld✓ErrorDHello WorldAnswerCorrect option: C. ErrorcView full question & answer→
MCQ 31 MarkWhat will be the output? >>>d1 = {“Naveen ”:40, “Shailender ”:45} >>>“Naveen ”in d1✓1B0CNoneDErrorAnswerCorrect option: A. 1aView full question & answer→
MCQ 41 MarkWhat will be the output? >>>d1 = {“Naveen ”:40, “Shailender ”:45} >>>d2 = {“Naveen ”:466, “Shailender ”:45} >>>d1==d2A1✓0CNoneDErrorAnswerCorrect option: B. 0bView full question & answer→
MCQ 51 MarkWhat is the output of the following piece of code when executed in Python shell? >>>a=(5,6) >>>b=(9,8) >>>c=a+b >>>c✓(5, 6, 9, 8)B(14,14)CError as the tuples are immutableDNoneAnswerCorrect option: A. (5, 6, 9, 8)aView full question & answer→
MCQ 61 MarkWhat is the output of the following code? a= [1, 2, 3, 4, 5] for i in range(1, 5): a[i-1] = a[i] for i in range(0, 5): print(a[i],end = ““)A5 5 1 2 3B5 1 2 3 4C2 3 4 5 1✓2 3 4 5 5AnswerCorrect option: D. 2 3 4 5 5dView full question & answer→
MCQ 71 MarkWhat is the output of the following code? a=[13,56,17] a.append([87]) a.extend([45,67]) print(a)✓[13, 56, 17, [87], 45, 67].B[13, 56, 17, 87, 45, 67].C[13, 56, 17, 87,[ 45, 67]].D[13, 56, 17, [87], [45, 67]].AnswerCorrect option: A. [13, 56, 17, [87], 45, 67].aView full question & answer→
MCQ 81 MarkSuppose list1 is [4, 2, 2, 4, 5, 2, 1, 0], Which of the following is correct syntax for slicing operation?Aprint(list1[0])Bprint(list1[:2])Cprint(list1[:-2])✓all of the theseAnswerCorrect option: D. all of the thesedView full question & answer→
MCQ 91 MarkSuppose listExample is ['h','e','l','l','o'], what is len(listExample)?✓5B4CNoneDErrorAnswerCorrect option: A. 5aView full question & answer→
MCQ 101 MarkWhich of the following commands will create a list?Alist1 = list()Blist1 = [].Clist1 = list([1, 2, 3])✓all of the theseAnswerCorrect option: D. all of the thesedView full question & answer→
MCQ 111 MarkWhat is the output of the following? print('rachna sagar'.title())ARACHNA SAGAR✓Rachna SagarCRachna sagarDNone of the aboveAnswerCorrect option: B. Rachna SagarbView full question & answer→
MCQ 121 MarkWhat is the output of the following? print('RachnaSagar'.split('na', 2))A['Rach', 'naSagar']✓['Rach', 'Sagar']C['Rachna', 'Sagar']D['Rach','na', 'Sagar']AnswerCorrect option: B. ['Rach', 'Sagar']bView full question & answer→
MCQ 131 MarkIn order to store values in terms of key and value which data type will you use?AListBTupleCClass✓dictionaryAnswerCorrect option: D. dictionarydView full question & answer→
MCQ 141 MarkWhat data type is the object below ? L = [1, 23, 'hello', 1].✓listBdictionaryCarrayDtupleAnswerCorrect option: A. listaView full question & answer→
MCQ 151 MarkWhat will be the output of the given statements: dict= {'Dhoni':7, 'Kohli':18, 'Sachin':10} print(dict.keys())Adict_keys(['Dhoni', 'Sachin'])✓dict_keys(['Dhoni', 'Kohli', 'Sachin'])Cdict_values([7, 18, 10])Ddict_values([0,1,2])]AnswerCorrect option: B. dict_keys(['Dhoni', 'Kohli', 'Sachin'])bView full question & answer→
MCQ 161 MarkEmpty list can be defined as:A““B 'C( )✓[ ]AnswerCorrect option: D. [ ]dView full question & answer→
MCQ 171 MarkDictionary is declared with:✓{}B[]C()DDouble quotesAnswerCorrect option: A. {}aView full question & answer→
MCQ 181 MarkFor slicing ____________ brackets will be used:A{}B()✓[]DAny of the aboveAnswerCorrect option: C. []cView full question & answer→
MCQ 191 MarkOutput of the given code will be: str=”Computer ” print(str[2:3])Ap✓mCteDoAnswerCorrect option: B. mbView full question & answer→
MCQ 201 Markoncatenation Operator in list is:A*B,✓+D=AnswerCorrect option: C. +cView full question & answer→
MCQ 211 MarkOOP's Full form is:AObject Based Oriented Language✓Object Oriented LanguageCOpen Object LanguageDOriented Object LanguageAnswerCorrect option: B. Object Oriented LanguagebView full question & answer→