comments removed
This commit is contained in:
parent
bd4374c810
commit
3c8fea51a8
1 changed files with 0 additions and 4 deletions
|
@ -14,7 +14,6 @@ class DayThree implements Solvable {
|
|||
.map(arr => Number.parseInt(arr))
|
||||
}
|
||||
|
||||
|
||||
public part1(): Solvable {
|
||||
const re = /mul\([0-9]{1,3},[0-9]{1,3}\)/g
|
||||
// get all matches and parse them to int[]
|
||||
|
@ -33,7 +32,6 @@ class DayThree implements Solvable {
|
|||
let active = true
|
||||
let result = 0
|
||||
for (const inst of instructions) {
|
||||
console.log((active ? '' : 'skipping ') + inst )
|
||||
if (inst === 'do()') {
|
||||
active = true
|
||||
continue
|
||||
|
@ -45,8 +43,6 @@ class DayThree implements Solvable {
|
|||
if (active) {
|
||||
const [left, right] = this.multiplyInstruction(inst)
|
||||
result += left * right
|
||||
console.log((active ? 'multiplying ' : '' ), left, right)
|
||||
console.log(left, right)
|
||||
}
|
||||
}
|
||||
console.log(result)
|
||||
|
|
Loading…
Reference in a new issue