Operators, precedence and expression evaluation Theory
What We'll Learn
A quick overview of today's lecture
Operators, precedence and expression evaluation Theory
Concept ID: U1_OPERATORS_EXPRESSIONS.
Primary Sub-subtopic: Operators, precedence and expression evaluation.
Question-bank grouping: Revision of Python & Core Concepts.
Use this lecture for theory, examples, misconceptions, and short concept checks mapped to this concept ID.
Key things we'll cover
Operators, precedence and expression evaluation
PYQ references used by both prompts23 included0 excluded
Flagged questions are excluded from both Study Notes and PPT references until corrected in Paper Analyzer.
Included
ID 6506 · 2021 · 1 mark(s)
Evaluate the following expression and identify the correct answer.
16 - (4 + 2) * 5 + 2**3 * 4
a) 54
b) 46
c) 18
d) 32
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6530 · 2022 · 1 mark(s)
Consider the given expression:
not True and False or True
Which of the following will be correct output if the given expression is evaluated?
a) True
b) False
c) NONE
d) NULL
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6540 · 2022 · 1 mark(s)
What will the following expression be evaluated to in Python?
print(15.0 / 4 + (8 + 3.0))
a) 14.75
b) 14.0
c) 15
d) 15.5
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6090 · 2023 · 1 mark(s)
Consider the given expression :
5<10 and 12>7 or not 7>4
Which of the following will be the correct output, if the given expression is evaluated ?
(a) True
(b) False
(c) NONE
(d) NULL
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6094 · 2023 · 1 mark(s)
Which of the following operators will return either True or False ?
(a) +=
(b) !=
(c) =
(d) x=
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6100 · 2023 · 1 mark(s)
What will the following expression be evaluated to in Python ?
print (4+3*5/3-5%2)
(a) 8.5
(b) 8.0
(c) 10.2
(d) 10.0
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6287 · 2023 · 1 mark(s)
Consider the given expression :
7<4 or 6>3 and not 10==10 or 17>4
Which of the following will be the correct output if the given expression is evaluated ?
(a) True
(b) False
(c) NONE
(d) NULL
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6291 · 2023 · 1 mark(s)
Which of the following is an example of identity operators of Python ?
(a) is
(b) on
(c) in
(d) not in
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6297 · 2023 · 1 mark(s)
What will the following expression be evaluated to in Python ?
print (6/3 + 4**3//8-4)
(a) 6.5
(b) 4.0
(c) 6.0
(d) 4
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6136 · 2024 · 1 mark(s)
Which of the following are the valid logical operators in Python ?
(A) and, or, not
(B) AND, OR, NOT
(C) &&, ||, !
(D) &, |, ~
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6329 · 2024 · 1 mark(s)
What will be the output of the following statement ?
print(6+5/4**2//5+8)
(A) –14.0
(B) 14.0
(C) 14
(D) –14
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6613 · 2024 · 1 mark(s)
Which of the following expressions evaluates to False?
a) not(True) and False
b) True or False
c) not(False and True)
d) True and not(False)
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6633 · 2024 · 2 mark(s)
Give two examples of each of the following:
(I) Arithmetic operators
(II) Relational operators
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6174 · 2025 · 1 mark(s)
What will be the output of the following statement?
print(14%3**2*4)
(A) 16
(B) 64
(C) 20
(D) 256
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6179 · 2025 · 1 mark(s)
Which of the following operator evaluates to True if the variable on either side of the operator points towards the same memory location and False otherwise?
(A) is
(B) is not
(C) and
(D) or
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6371 · 2025 · 1 mark(s)
What is the value of the following expression ?
3 + 3.00, 3**3.0
(A) [6.0, 27.0]
(B) (6.0, 9.0)
(C) (6, 27)
(D) (6.0, 27.0)
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6379 · 2025 · 1 mark(s)
State whether the following statement is True or False.
In Python, the print() evaluates the expression before displaying it on the screen.
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6663 · 2025 · 1 mark(s)
Consider the given expression:
print(19<11 and 29>19 or not 75>30)
Which of the following will be the correct output of the given expression?
a) True
b) False
c) Null
d) No output
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6667 · 2025 · 1 mark(s)
What will be the output of the following Python statement:
print(10-3**2**2+144/12)
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6201 · 2025 · 2 mark(s)
Evaluate the expressions as asked in the questions (a) and (b) given below:
(a) Given A = -2 and B = 7, find:
A >= -3 or B > 10
(b) Given X = True, evaluate:
not X
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6390 · 2025 · 2 mark(s)
What is the difference between = and == in Python ? Give an example of each.
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6391 · 2025 · 2 mark(s)
Give an example of each of the following :
(i) An expression using any one identity operator.
(ii) An arithmetic expression which uses any one augmented assignment operator.
Revision of Python & Core Concepts → Operators precedence and expression evaluation
Included
ID 6220 · 2026 · 1 mark(s)
Which of the following expressions in Python evaluates to True ?
(A) 2>3 and 2<3
(B) 3>1 and 2
(C) 3>1 and 3>2
(D) 3>1 and 3<2
Revision of Python & Core Concepts → Operators precedence and expression evaluation