Made "use strict" Global & Made JSLint Happy

This commit is contained in:
PatOnTheBack
2019-08-05 15:34:17 -04:00
committed by GitHub
parent ef7b5bd119
commit 66600374be

View File

@ -9,11 +9,12 @@
https://en.wikipedia.org/wiki/Least_common_multiple
*/
"use strict";
// Find the LCM of two numbers.
function find_lcm(num_1, num_2) {
"use strict";
var max_num,
lcm;
var max_num;
var lcm;
// Check to see whether num_1 or num_2 is larger.
if (num_1 > num_2) {
max_num = num_1;
@ -32,6 +33,6 @@ function find_lcm(num_1, num_2) {
}
// Run `find_lcm` Function
var num_1 = 12,
num_2 = 76;
var num_1 = 12;
var num_2 = 76;
console.log(find_lcm(num_1, num_2));