Font size
WorksheetsPL101 MIDTERM Long Quiz
Total questions: 35
Worksheet time: 23mins
It is a cross-platform programming language that can run on multiple platforms like Windows, macOS, and Linux.
C
C++
Python
None of the choices
Python is _____.
free and open-source
free and available online
multi languages and open-source
None of the choices
____ are the reserved words in Python.
Method
Keywords
Module
None of the choices
In Python, keywords are _____.
uppercase
lowercase
case-sensitive
None of the choices
All the keywords except True, False and None are in _____ and they must be written as they are
uppercase
lowercase
case-sensitive
None of the choices
_____ is a name given to entities like class, functions, variables, etc.
Identifier
Module
Keywords
None of the choices
An identifier cannot start with a _____.
uppercase letter
lowercase letter
digit
None of the choices
An identifier cannot start with a _____.
uppercase letter
lowercase letter
digit
None of the choices
Always give the identifiers a name that _____.
make values
makes sense
make variable
None of the choices
In creating multiple words identifier it can be separated using an _____, like this_is_a_long_variable.
space
underscore
symbols
None of the choices
Instructions that a Python interpreter can execute are called (a) .
To define a block of code in Python we uses (a) .
(a) describe what is going on inside a program.
A (a) is a named location used to store data in the memory.
A (a) is a type of variable whose value cannot be changed.
(a) is a raw data given in a variable or constant.
A (a) is a sequence of characters surrounded by quotes.
A (a) literal can have any of the two values: True or False.
We can use the (a) function to know which class a variable or a value belongs to.
(a) can be of any length, it is only limited by the memory available.
In _____ type conversion, Python automatically converts one data type to another data type.
Explicit
implicit
conversion
None of the choices
In _____Type Conversion, users convert the data type of an object to the required data type.
Explicit
implicit
conversion
None of the choices
In _____Type Conversion, users convert the data type of an object to the required data type.
Explicit
implicit
conversion
None of the choices
In Python, we can simply use the _____ function to print output.
printf()
print()
printing()
None of the choices
To take the input from the user in Python, we can use the _____ function.
get()
scanf()
input()
None of the choices
a = 5 b =2 ; print (a < b)
True
False
a = 5 b =2 ; print(a != b)
True
False
a = 10 b =4 ; print(a >= b)
True
False
a = 10 b =10 ; print(a <= b)
True
False
a = 5 b =6 ; print((a > 2) and (b >= 6))
True
False
a = 2 b =3 ; print((a > 2) and (b >= 6))
True
False
print(not True)
True
False
a = 1 b =3 ; print((a > 2) or (b >= 6))
True
False
a = 6 b =2 ; print((a > 2) or (b >= 6))
True
False
num1 = 6 num2 =6 ; print(num1 is not num2)
True
False
