diff --git a/d12/log b/d12/log new file mode 100644 index 0000000..3f97e07 --- /dev/null +++ b/d12/log @@ -0,0 +1,2 @@ +12818 too high +9863 too high diff --git a/d12/p1reveal.txt b/d12/p1reveal.txt new file mode 100644 index 0000000..e2bdf5e --- /dev/null +++ b/d12/p1reveal.txt @@ -0,0 +1,6 @@ +#.#.### 1,1,3 +.#...#....###. 1,1,3 +.#.###.#.###### 1,3,1,6 +####.#...#... 4,1,1 +#....######..#####. 1,6,5 +.###.##....# 3,2,1 diff --git a/d13/p1.lua b/d13/p1.lua new file mode 100644 index 0000000..03c4c6d --- /dev/null +++ b/d13/p1.lua @@ -0,0 +1,23 @@ +local function calc(lines) + for i, line in ipairs(lines) do + print(line) + + if line == lines[#lines - i + 1] then + end + end + +end + +while true do + local lines = {}; + local line = io.read("l") + + if line == nil then + break + elseif line == "" then + calc(lines) + else + lines[#lines+1] = line + end +end +