Skip to content

Commit

Permalink
🎄 Add solution to 2024-12-25
Browse files Browse the repository at this point in the history
  • Loading branch information
fuglede committed Dec 27, 2024
1 parent 7578361 commit 2ffbf08
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions 2024/day25/solutions.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
from itertools import combinations

with open("input") as f:
gs = f.read().strip().split("\n\n")

# Part 1
print(
sum(
not any(x1 == x2 == "#" for x1, x2 in zip(g1, g2))
for g1, g2 in combinations(gs, 2)
)
)

0 comments on commit 2ffbf08

Please sign in to comment.