--- id: math-hypot name: Math.hypot category: math kind: namespace-method tokens: Math.hypot sig: Math.hypot(x, y) -> fixed tip: Length of the vector (x, y). order: 15 ns: Math member: hypot --- Returns sqrt(x*x + y*y) — the length of the 2D vector (x, y), or equivalently the hypotenuse of a right triangle with those legs. It is the one-call form for a magnitude and reads more clearly than spelling out the squares and root. To normalize a vector, divide each component by its Math.hypot. ```ludic program Demo { handler Step phase Update { let length = Math.hypot(velocity_x, velocity_y) } } ```