floor()

Prototype: double floor(double Value);
Header File: cmath
Explanation: Returns the largest interger value smaller than or equal to Value. (Rounds down)




Example:
//Example will output 5.9 rounded down
#include <cmath>
#include <iostream>

using namespace std;

int main()
{
  cout<<"5.9 rounded down: "<<floor(5.9);
}
Other Functions