Similar Collections


Here you will get Python basics Quiz as Multiple Choice Questions And Answers for you next job or exam

questions

Title
Given a function that does not return any value, What value is thrown by default when executed in shell
What is the maximum possible length of an identifier?
What will be the output of the following Python code?
What are the values of the following Python expressions?
What is the value of the following expression?8/4/2, 8/(4/2) The above expressions are evaluated as: 2/2, 8/2, which is equal to (1.0, 4.0)
What will be the output of the following Python code?
Given a string example=”hello” what is the output of example.count(‘l’)?
Read the information given below carefully and write a list comprehension such that the output is: [‘e’, ‘o’]
What will be the output of the following Python list comprehension?
The function pow(x,y,z) is evaluated as:
What will be the output of the following Python function?
What will be the output of the following Python code? l=[2, 3, [4, 5]] l2=l.copy() l2[0]=88 l l2
What will be the output of the following Python code and state the type of copy that is depicted? l1=[2, 4, 6, 8] l2=[1, 2, 3] l1=l2 l2
What will be the output? ef fact(num): if num == 0: return 1 else: return _____________________
What will be the output of the following Python code? def f1(a,b=[]): b.append(a) return b print(f1(2,[3,4]))
Program code making use of a given module is called a ______ of the module
Which function overloads the + operator?
Which operator is overloaded by __invert__()?
Let A and B be objects of class Foo. Which functions are called when print(A + B) is executed?
What will be the output of the following Python code?
total questions: 49

Questions

49

Views

843

Best Answers

299

Points

5