How to make the mod of a negative number to be positive?
<p>Basically, I need <code>(-3) % 5</code> to be "2" instead of "-3". Python produces "2", but C++ produces "-3". Not sure how to produce "2" in C++. Thanks!</p>
