use "floor" in math.h header file to round a double or float variable like:

PHP Code:
cout<<floor(3.4);