Skip to content

Commit

Permalink
feat: remove spurious transpose
Browse files Browse the repository at this point in the history
  • Loading branch information
Panadestein committed Dec 4, 2024
1 parent f44b7f7 commit e808087
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/aoc24.org
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ These definitions and imports are shared by the various puzzles:
IV ← {
inp ← >•FLines Input 𝕩
t‿ts ← ⟨"XMAS"‿"SAMX", "MSAMS"‿"SMASM"‿"SSAMM"‿"MMASS"⟩
eins ⇐ t ⍷{+´+´∘⥊¨⟨+´𝕨𝔽¨<𝕩, +´𝕨𝔽¨<⍉𝕩, ∾+˝𝕨𝔽⌜𝔾𝕩, ∾+˝𝕨𝔽⌜𝔾⌽𝕩⟩}(⊢⊔˜·+⌜´↕¨∘≢) inp
eins ⇐ t ⍷{+´+´∘⥊¨⟨+´𝕨𝔽¨<𝕩, +´𝕨𝔽¨<⍉𝕩, ∾+˝𝕨𝔽⌜𝔾𝕩, ∾+˝𝕨𝔽⌜𝔾⌽𝕩⟩}(⊢⊔˜·+⌜´↕¨∘≢) inp
xm ← ⌽˘⊸∨=⌜˜↕3 ⋄ zwei ⇐ +´⥊{ts≡¨<xm/○⥊𝕩}⎉2 3‿3↕inp
}
IV _is 4
Expand Down
2 changes: 1 addition & 1 deletion src/bqn/aoc24.bqn
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ III _is 3
IV ← {
inp>•FLines Input 𝕩
tts ← ⟨"XMAS""SAMX", "MSAMS""SMASM""SSAMM""MMASS"
einst {+´+´¨+´𝕨𝔽¨<𝕩, +´𝕨𝔽¨<⍉𝕩, ∾+˝𝕨𝔽𝔾𝕩, ∾+˝𝕨𝔽𝔾⌽𝕩⟩}(⊢⊔˜·+⌜´¨) inp
einst {+´+´¨+´𝕨𝔽¨<𝕩, +´𝕨𝔽¨<⍉𝕩, ∾+˝𝕨𝔽𝔾𝕩, ∾+˝𝕨𝔽𝔾⌽𝕩⟩}(⊢⊔˜·+⌜´¨) inp
xm˘∨=⌜˜3zwei+´{ts¨<xm/𝕩}2 33inp
}
IV _is 4

0 comments on commit e808087

Please sign in to comment.