advent
individual solutions at AoC (by martino-vic)
adventofcode
My solutions to the Advent of Code challenges (by djotaku)
advent | adventofcode | |
---|---|---|
8 | 69 | |
0 | 14 | |
- | - | |
1.8 | 8.6 | |
over 2 years ago | 5 months ago | |
Jupyter Notebook | Python | |
- | - |
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
advent
Posts with mentions or reviews of advent.
We have used some of these posts to build our list of alternatives
and similar projects. The last one was on 2021-12-24.
-
-🎄- 2021 Day 25 Solutions -🎄-
Day 25 Solution
-
[2021 Day 20 (Part 1)][Python] Is there a flaw in my logic?
I can't find an answer to what causes my script to give the right answer to the example but not to the real input. The workflow looks like this: 1. the padding-character is "." 2. expand the input-matrix by 1 padding-character in each direction 3. for each pixel of the expanded image query the surrounding 8 pixels. If out of bounds add the pudding character instead. 4. flip the pudding from "." to "#" or from '#' to '.' if necessary. 5. Go back to step 2 and repeat the process with the new image
-
[2021 Day 18 (Part 1)][Python 3] bug in final example
With the help of reddit users and endless patience I got this far: https://github.com/martino-vic/Advent/blob/master/day18/day18_3.ipynb It passes all the tests, *except* for the final example homework assignment, which I have saved in file "i3". I'd actually not only be curious what the bug here might be, but maybe in this case it would be more useful to learn how to debug these kind of cases efficiently. What worked until now was a print() and input() statement in the while loop so I could track step by step what is happening. But with this many additions and reductions it's simply impossible to catch a bug that way. So I'm thinking about what strategies could exist to identify a bug in a scenario like this, especially if all the previous tests (including the "slightly larger example") are passing. Any help - as always - much appreciated!
-
[2021 Day 18 (Part 1)][Python 3] infinite loop at "[[[0,[4,5]],[0,0]],[[[4,5],[2,6]],[9,5]]] [7,[[[3,7],[4,3]] + [[6,3],[8,8]]]]"
I spent the entire day with this but didn't manage to get a silver star: https://github.com/martino-vic/Advent/blob/master/day18/day18_2.ipynb I intensly hope someone can help me out... I cleaned up the code so it's easier to see what's going on. It works well until the " Here's a slightly larger example: "-part. I have the feeling it must be some trivial mistake but I can't figure it out and with my current tiredness level I've lost hope that I will. At one point the code enters an infinite loop and I can't figure out how to snap out of it. I've put an input() statement in one line, so that the while loop doesn't run away and one can track round by round what is happening. Maybe someone had some similar issue as me and can quickly point out the issue? Any hints and any help much appreciated!
-
[2021 Day 15 (Part 1)][Python] correct for easy example wrong for real input
Didn't manage to get a silver star, similar situation as yesterday: I get the correct output for the easier input-example and for the real input the answer is wrong and it's a complete mystery to me why. Tinkered around for 2.5h before I gave up: https://github.com/martino-vic/Advent/tree/master/day15
-
poly 40 iterations
[2021 14 #part2] Python 3: https://github.com/martino-vic/Advent/tree/master/day14
-
-🎄- 2021 Day 10 Solutions -🎄-
Python 3 part1: https://github.com/martino-vic/Advent/tree/master/day14 got a silver star quite quickly by using nltk's ngrams. Part 2 tripped me up, works only for the easy input but for the proper one it gives me the wrong output, no idea why :/
adventofcode
Posts with mentions or reviews of adventofcode.
We have used some of these posts to build our list of alternatives
and similar projects. The last one was on 2022-12-24.
-
[2023 Day 04 (Part 2)][Python] Need help with recursion
I tried to model my code https://github.com/djotaku/adventofcode/blob/6c5d9c6e4f2dcbbbf7383b2923829c210faab028/2023/Day_04/Python/day_04.py (specifically lines 42-56) on my solution for Handy Haversacks in 2020 Day 7, but I'm ending up with an answer of 1 instead of 30. It seems like the problem is that my totals are not carrying up the stack, but I may have something else wrong.
- -🎄- 2022 Day 25 Solutions -🎄-
- -🎄- 2022 Day 20 Solutions -🎄-
- [2022 Day 18 (Part 1)][Python] What is wrong with my math?
- [2022 Day 15 (Part 1)] [Python] Need help with my algorithm
- -🎄- 2022 Day 14 Solutions -🎄-
-
-🎄- 2022 Day 13 Solutions -🎄-
My code is here https://github.com/djotaku/adventofcode/blob/66d74babd2ed37f56858096bc5598149448b6839/2022/Day_13/Python/solution.py
- [2016 Day 25 (Part 1)][Python] I keep getting 00000 or 111111
- -🎄- 2022 Day 12 Solutions -🎄-
- -🎄- 2022 Day 11 Solutions -🎄-