2

http://en.cppreference.com/w/c/numeric/math/fmod

Alright, cool. There's this function called fmod, but it appears to only work with float, double, and long double. Is there a version of this function that works with integers in C++?

Aaron Franke
  • 3,268
  • 4
  • 31
  • 51

1 Answers1

4

Yes, '%' is used for modulus operator, as Joducus said in the comment. See example.

TheGreatContini
  • 6,429
  • 2
  • 27
  • 37