Opens in a new tab
A picture of Jeff Brigman
I CODE TODAY FOR
A BETTER TOMORROW

Glossary Term

Math.floor()

2 tags 1 category

The Math.floor() static method always rounds down and returns the largest integer less than or equal to a given number.

Because floor() is a static method of Math, you always use it as Math.floor(), rather than as a method of a Math object you created (Math is not a constructor).

Return value: The largest integer smaller than or equal to x. It’s the same value as -Math.ceil(-x).

Syntax example: Math.floor(x)

Term Connections

Explore related terms connected by shared tags, shared categories, and relationship phrases. This map loads only when it comes into view.

Loading term connections…