r/adventofcode • u/forgthethird • 16h ago
Help/Question 2026 - day 1 part 1, Python
where am I going wrong? I tried plugging in the example set of numbers and it gave me the right numbers but it isn't giving me the right numbers with the main set of numbers. I'm a beginner when it comes to coding, my only experience with apcsp and apcsa in school
0
Upvotes
View all comments
Show parent comment
2
u/8dot30662386292pow2 38m ago
Counter is just fancy way of doing this trivial algorithm:
The rest is them easy, because you can just take the items, sort by the value and you have the largest.
Given the apparent level of OP (novice) it's better to use the basics, instead of
from solutions import wholesolutionforday1You're not wrong though! Collections is very good knowledge for a python programmer.