WorksheetsPython test 1
Total questions: 10
Worksheet time: 5mins
Who developed Python Programming Language?
Wick van Rossum
Rasmus Lerdorf
Guido van Rossum
Niene Stom
Which of the following is the correct extension of the Python file?
.python
.pl
.py
.p
Is Python code compiled or interpreted?
Python code is both compiled and interpreted
Python code is neither compiled nor interpreted
Python code is only compiled
Python code is only interpreted
What will be the value of the following Python expression?
4 + 3 % 5
7
2
4
1
Which of the following is used to define a block of code in Python language?
Indentation
Key
Brackets
All of the mentioned
In which year was the Python language developed?
1995
1972
1981
1989
Which of the following character is used to give single-line comments in Python?
//
#
!
/*
What will be the output of the following Python code?
i = 1
while True:
if i%3 == 0:
break
print(i)
i + = 1
123
Error
12
321
What is the order of precedence in python?
Exponential, Parentheses, Multiplication, Division, Addition, Subtraction
Exponential, Parentheses, Division, Multiplication, Addition, Subtraction
Parentheses, Exponential, Multiplication, Addition, Division, Subtraction
Parentheses, Exponential, Multiplication, Division, Addition, Subtraction
Which of the following functions is a built-in function in python?
factorial()
print()
seed()
sqrt()
