diff --git a/javascript/day1.js b/javascript/day1.js deleted file mode 100644 index e69de29..0000000 diff --git a/javascript/day1/day1.js b/javascript/day1/day1.js new file mode 100644 index 0000000..13242bb --- /dev/null +++ b/javascript/day1/day1.js @@ -0,0 +1,19 @@ +import * as fs from "fs" +let data = fs.readFileSync("inputday1.txt").toString() + +data = data.replaceAll("one", "o1e") +data = data.replaceAll("two", "t2o") +data = data.replaceAll("three", "t3e") +data = data.replaceAll("four", "f4r") +data = data.replaceAll("five", "f5e") +data = data.replaceAll("six", "s6x") +data = data.replaceAll("seven", "s7n") +data = data.replaceAll("eight", "e8t") +data = data.replaceAll("nine", "n9e") + +let sumNum = 0 +let lines = data.split("\n") + +for (let line of lines){ + +} \ No newline at end of file diff --git a/javascript/day2.js b/javascript/day2/day2.js similarity index 100% rename from javascript/day2.js rename to javascript/day2/day2.js