JavaScript » Math » floor

Syntax:
Math.floor(x)

This method returns an integer equal to, or the next integer less than, the number passed to it. Hence, if you passed it 3.79, it would return 3, and passing it -3.79 would return -4.