AdventOfCode2020

Solutions to all 25 AoC 2020 problems in Rust! :christmas_tree: (by AxlLind)

AdventOfCode2020 Alternatives

Similar projects and alternatives to AdventOfCode2020
NOTE: The number of mentions on this list indicates mentions on common posts. Hence, a higher number means a better alternative or higher similarity.

Posts

Posts where AdventOfCode2020 has been mentioned. We have used some of these posts to build our list of alternatives and similar projects - the last one was on 2021-01-26.
  • [2020 Day 9] Part 2 - What is the most efficient algorithm?
    One important thing to note is that all numbers in the input are positive. Since they are all positive it can be solved quite easily in linear time, O(n), and O(1) memory complexity. See algorithm here. I used this algorithm in my Rust solution.
  • Advent of Code 2020 - Final Day: 25
    reddit.com/r/rust | 2020-12-24
    Link to solution (346/284)
  • -🎄- 2020 Day 25 Solutions -🎄-
    Link to solution (346/284)
  • Advent of Code 2020 - Day 24
    reddit.com/r/rust | 2020-12-23
    Link to solution (992/628)
  • -🎄- 2020 Day 24 Solutions -🎄-
    Link to solution (992/628)
  • -🎄- 2020 Day 23 Solutions -🎄-
    Link to solution (1180/560)
  • 2020 Day 20 Solutions
    Link to solution (359/116)
  • [2020, Day 22, Part 2] Is there a way to speed up the state checking?
    A solution that will work with very high probability (which I used here) is to store a hashset of hashes, HashSet. E.g you compute a hash for the two queues and see if that hash has already been seen. There is a very, very, small probability of a hash collision, but in practice this works.
  • Advent of Code 2020 - Day 22
    reddit.com/r/rust | 2020-12-21
    Link to solution (471/281)
  • -🎄- 2020 Day 22 Solutions -🎄-
    Link to solution (471/281)
  • 2020 Day 21 Solutions
    For part one, I compute the intersection of ingredients between all lists containing a certain allergen. Then it was the same process as day 16, whereby you eliminate possibilities by iteratively looking at what allergen only has one possible ingredient it can be. Once again, this leads to a unique solution in our input.
    Link to solution (1323/898)
  • Advent of Code 2020 - Day 21
    reddit.com/r/rust | 2020-12-20
    For part one, I compute the intersection of ingredients between all lists containing a certain allergen. Then it was the same process as day 16, whereby you eliminate possibilities by iteratively looking at what allergen only has one possible ingredient it can be. Once again, this leads to a unique solution in our input.
    reddit.com/r/rust | 2020-12-20
    Link to solution (1323/898)

Stats

Basic AdventOfCode2020 repo stats
1
17
8.8
8 days ago

AxlLind/AdventOfCode2020 is an open source project licensed under MIT License which is an OSI approved license.