An open API service indexing awesome lists of open source software.

https://github.com/raeperd/advent-of-code


https://github.com/raeperd/advent-of-code

Last synced: 5 months ago
JSON representation

Awesome Lists containing this project

README

          

# Advent of Code 2025

Solutions for [Advent of Code 2025](https://adventofcode.com/) in Python.

## 01
- edge case on starting from 0
- + and - handling for mod
- simple while can fix issue
- linear thinking for circular problems - count multiples crossed instead of simulating
- integer division for boundaries - `(n // 100) * 100` finds nearest multiples

## 02
- care max number of partition
- `for-else` - detects loop completion without break
- divisibility filters patterns early - `len % k == 0` before checking

## 03
- finding max value, greedy might work
- suffix constraint - when picking k items, leave room for remaining picks
- greedy works for lex-max - highest digit first always wins

## 04
- variable scope matters - reset counter per cell, not per row
- only check target cells (`@`), not all cells in grid
- 8-direction neighbor check - tuple iteration `(di, dj)` with bounds checking
- repeated removal - loop until no changes in a pass