diff --git a/script.js b/script.js index fcc6d25..73a4885 100644 --- a/script.js +++ b/script.js @@ -68,18 +68,6 @@ inputOnChange(); let process = 1; //resize burst time rows size on +/- -function gcd(x, y) { - while (y) { - let t = y; - y = x % y; - x = t; - } - return x; -} - -function lcm(x, y) { - return (x * y) / gcd(x, y); -} function lcmAll() { let result = 1; diff --git a/utils.js b/utils.js new file mode 100644 index 0000000..ed5bccc --- /dev/null +++ b/utils.js @@ -0,0 +1,14 @@ +function gcd(x, y) { + while (y) { + let t = y; + y = x % y; + x = t; + } + return x; +} + +function lcm(x, y) { + return (x * y) / gcd(x, y); +} + +