mirror of
https://github.com/seigler/advent-of-code-browser-console
synced 2025-07-25 07:46:09 +00:00
2022 Day 1
This commit is contained in:
parent
fc6c4c750f
commit
7c035a8b0b
2 changed files with 2 additions and 2 deletions
3
.replit
3
.replit
|
@ -1,2 +1 @@
|
|||
language = "nodejs"
|
||||
run = "node day04"
|
||||
language = 'nodejs';
|
||||
|
|
1
2022/day01.js
Normal file
1
2022/day01.js
Normal file
|
@ -0,0 +1 @@
|
|||
[a,b,c]=$("pre").innerText.trim().split`\n\n`.map(x=>x.split`\n`.reduce((a,c)=>a+(+c),0)).sort((a,b)=>b-a);[a,a+b+c]
|
Loading…
Add table
Add a link
Reference in a new issue