aoc22
Solutions for Advent of Code 2022 in Rust (by morlinbrot)
Advent-of-Code
By Catterwaul
aoc22 | Advent-of-Code | |
---|---|---|
3 | 11 | |
0 | 1 | |
- | - | |
10.0 | 10.0 | |
over 1 year ago | over 1 year ago | |
Rust | Swift | |
- | - |
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.
aoc22
Posts with mentions or reviews of aoc22.
We have used some of these posts to build our list of alternatives
and similar projects. The last one was on 2022-12-11.
-
-๐- 2022 Day 12 Solutions -๐-
Here's just the interesting bit, full solution here. ``` fn dijkstra(unvisited: &mut Unvisited, start: Pos, end: Pos) -> Option { fn update_neighbor(unvisited: &mut Unvisited, cur: &Node, pos: Pos) { if let Some(neigh) = unvisited.get_mut(&(pos)) { // Steepness check. if neigh.val <= cur.val + 1 { neigh.dist = neigh.dist.min(cur.dist + 1.); } } }
-
-๐- 2022 Day 9 Solutions -๐-
Tiny little thing you could do to make this even more succinct: Use `abs()` on `dx` and `dy`, that's what I did!
-
-๐- 2022 Day 5 Solutions -๐-
HashMap for parsing stacks and Vec> for operations. Full code here.
Advent-of-Code
Posts with mentions or reviews of Advent-of-Code.
We have used some of these posts to build our list of alternatives
and similar projects. The last one was on 2022-12-11.
-
-๐- 2022 Day 12 Solutions -๐-
Swift. I tried to use GameplayKit's pathfinding, but I got fed up with it being in Objective-C and not working with subtypes properly. shortestPathSources is just an implementation of Dijkstra that works on matrices.
-
-๐- 2022 Day 11 Solutions -๐-
Swift.
-
-๐- 2022 Day 10 Solutions -๐-
Swift. Algorithms had me covered for Part 2, but I had to make something for Part 1 that would allow for getting the elements of a Sequence based on sorted offsets, without having to start from the beginning each time.
-
-๐- 2022 Day 9 Solutions -๐-
I recommend SIMD2โit can save you a lot of reinventing the 2D wheel!
-
-๐- 2022 Day 8 Solutions -๐-
Swift. We don't have good types for this. ๐คฎ
-
-๐- 2022 Day 6 Solutions -๐-
Swift. containsOnlyUniqueElements is not in the standard library; it relies on this Set initializer.
-
-๐- 2022 Day 5 Solutions -๐-
Works grood.
-
-๐- 2022 Day 4 Solutions -๐-
No, I edited my comment. I was wrong in thinking that there was a proper overload. The one I'm using is just from `extension Collection where Self.Element : Equatable` in the new _StringProcessing section for Regex. It gives the correct result, but it's not as fast as it could be. (https://stackoverflow.com/questions/64066681/check-if-one-range-is-within-another)
-
-๐- 2022 Day 2 Solutions -๐-
Swift, using some helpers for `CaseIterable`.
What are some alternatives?
When comparing aoc22 and Advent-of-Code you can also consider the following projects:
aoc - Advent of Code
AoC2022 - Solutions to the Advent of Code (AoC) 2022
advent_of_code_2022 - Advent of code 2022
advent-of-code-rust - ๐Starter template for solving Advent of Code in Rust.
advent-of-code-solved - My advent of code, in jqโฆ
AdventOfCode2022
aoc2022 - ๐
adventofcode - :christmas_tree: Advent of Code (2015-2023) in C#
aoc2022 - Trying to solve Advent of Code 2022 in 25 different languages (1 day = 1 language)
AOC2022 - Advent Of Code 2022
adventofcode - Solutions for problems from AdventOfCode.com
AdventOfCode - C# Advent of Code project
aoc22 vs aoc
Advent-of-Code vs AoC2022
aoc22 vs advent_of_code_2022
Advent-of-Code vs advent-of-code-rust
Advent-of-Code vs advent-of-code-solved
Advent-of-Code vs AdventOfCode2022
Advent-of-Code vs aoc2022
Advent-of-Code vs adventofcode
Advent-of-Code vs aoc2022
Advent-of-Code vs AOC2022
Advent-of-Code vs adventofcode
Advent-of-Code vs AdventOfCode