mirror of
https://github.com/JustinSDK/dotSCAD.git
synced 2025-09-24 21:41:33 +02:00
6 lines
130 B
OpenSCAD
6 lines
130 B
OpenSCAD
function __nearest_multiple_of_4(n) =
|
|
let(
|
|
remain = n % 4
|
|
)
|
|
(remain / 4) > 0.5 ? n - remain + 4 : n - remain;
|