19.0k views
20 votes
What are the value and data type (float, int, bool, or str) of this expression:

5 % 2

1 Answer

8 votes

Answer: float

Step-by-step explanation:

This is asking what would the remainder be of 5/2. I am not totally sure what you are asking but float is used with remainders because it could have a decimal like 3.33 that would throw an error for anything other than float.

User Mengdi Liang
by
3.5k points