Numbers — Integers vs Floats & Math Essentials
Understand integers vs floats, common Math helpers, safe rounding, parsing, and comparing floating numbers.
Intro to numbers
Goal: Handle numbers safely.
- Integers vs floats
- Math helpers
- Rounding and parsing
- Float comparison tips

Integer check
Number.isInteger tells whether a numeric value is an integer. All numbers share type "number".
// Integers and floats
const a = 5;
const b = 5.5;
console.log("a integer?", Number.isInteger(a));
console.log("b integer?", Number.isInteger(b));
console.log("type of a:", typeof a);

All lessons in this course
- Template Literals & Common String Operations
- Numbers — Integers vs Floats & Math Essentials
- Dates — Basics, Time Zones, Intl.DateTimeFormat