1

Why are the amounts of this two different?

math.remainder(3,2)

and

3%2

Ar So
  • 21
  • 4
  • Have you tried reading the docs? https://docs.python.org/3/library/math.html#math.remainder – kaya3 Mar 31 '21 at 04:49
  • math.remainder(3, 2) returns -1.0 for some reason – chess_lover_6 Mar 31 '21 at 04:50
  • 1
    Does this answer your question? [Difference between Python 3.7 math.remainder and %(modulo operator)](https://stackoverflow.com/questions/43845375/difference-between-python-3-7-math-remainder-and-modulo-operator) – ddejohn Mar 31 '21 at 04:50

0 Answers0