136k views
5 votes
Which ones of the following expressions have the same values?

i) int(10 / 3)
ii) int(9) / int (3.2)
iii) int(9 / 3.2)
iii) int(12.4) % 4i
v) int (15.9) / 4

1 Answer

4 votes

Final answer:

The expressions that have the same values are i) int(10 / 3) and iii) int(9 / 3.2), which both evaluate to 3.

Step-by-step explanation:

The expressions that have the same values are i) int(10 / 3) and iii) int(9 / 3.2). To understand this, let's break down each expression:

  1. i) int(10 / 3): In this expression, 10 is divided by 3, resulting in approximately 3.33. The int() function then converts this decimal value to an integer, which is 3.
  2. iii) int(9 / 3.2): Here, 9 is divided by 3.2, resulting in approximately 2.81. The int() function then converts this decimal value to an integer, which is 2.

So, both expressions i) int(10 / 3) and iii) int(9 / 3.2) have the same value of 3.

User Boris Modylevsky
by
7.5k points

No related questions found