Skip to content

Add year_2025 folder structure with Day 1 and Day 2 puzzle solutions#1

Merged
ericlevicky merged 4 commits intomainfrom
copilot/create-folder-for-year
Dec 2, 2025
Merged

Add year_2025 folder structure with Day 1 and Day 2 puzzle solutions#1
ericlevicky merged 4 commits intomainfrom
copilot/create-folder-for-year

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Dec 2, 2025

  • Create year_2025 folder in src/ with init.py
  • Create day_1 subfolder with solution (Secret Entrance)
    • Implemented dial rotation logic with modular arithmetic
    • Part 1: Count times dial lands on 0 after rotation
    • Part 2: Count every click where dial passes through or lands on 0
  • Create day_2 subfolder with solution (Gift Shop)
    • Implemented repeated sequence detection
    • Part 1: Sum all invalid product IDs (repeated digit patterns)
    • Part 2: Count all invalid product IDs
  • Create matching test structure in tests/year_2025/
  • All tests passing
  • Fix Flake8 F824 errors (unused global declarations) in:
    • src/year_2021/day-9/day9.py
    • src/year_2022/day_11/code.py
Original prompt

Make a folder for this year and copy in the question for day 1


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Co-authored-by: ericlevicky <5102738+ericlevicky@users.noreply.github.com>
Copilot AI changed the title [WIP] Add folder for this year and copy day 1 question Add year_2025 folder structure with Day 1 puzzle Dec 2, 2025
Copilot AI requested a review from ericlevicky December 2, 2025 12:17
@ericlevicky
Copy link
Copy Markdown
Owner

@copilot Solve it and do the same for day 2

Co-authored-by: ericlevicky <5102738+ericlevicky@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Dec 2, 2025

@copilot Solve it and do the same for day 2

Implemented solutions for both puzzles in commit abc5774:

Day 1 (Secret Entrance): Dial rotation puzzle - tracks landing/crossing position 0 using modular arithmetic.

Day 2 (Gift Shop): Invalid product ID detection - finds numbers with repeated digit sequences (e.g., 55, 1010, 123123) and sums/counts them.

Both have full test coverage and are passing.

Copilot AI changed the title Add year_2025 folder structure with Day 1 puzzle Add year_2025 folder structure with Day 1 and Day 2 puzzle solutions Dec 2, 2025
@ericlevicky ericlevicky marked this pull request as ready for review December 2, 2025 13:19
@ericlevicky
Copy link
Copy Markdown
Owner

@copilot the tests failed, fix them

Co-authored-by: ericlevicky <5102738+ericlevicky@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Dec 2, 2025

@copilot the tests failed, fix them

Fixed in cbb20e2. The CI was failing due to pre-existing Flake8 F824 errors (unused global declarations) in src/year_2021/day-9/day9.py and src/year_2022/day_11/code.py. Removed the unnecessary global statements - they were only reading/mutating module-level variables, not assigning to them.

@ericlevicky ericlevicky merged commit a14fd7a into main Dec 2, 2025
1 check passed
@ericlevicky ericlevicky deleted the copilot/create-folder-for-year branch December 2, 2025 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants