Why does 2 mod 4 = 2?

NewToThis picture NewToThis · Aug 29, 2009 · Viewed 294k times · Source

I'm embarrassed to ask such a simple question. My term does not start for two more weeks so I can't ask a professor, and the suspense would kill me.

Why does 2 mod 4 = 2?

Answer

Jarsen picture Jarsen · Aug 29, 2009

Mod just means you take the remainder after performing the division. Since 4 goes into 2 zero times, you end up with a remainder of 2.