Skip to content

MrRobb/advent-of-code-2019

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

49 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Advent of Code 2019

HitCount license

Problem Solution Time execution Finished
Day 1 Problem 1 day1.rs 2.7 ms ± 0.5 ms
Day 2 Problem 2 day2.rs 5.2 ms ± 0.5 ms
Day 3 Problem 3 day3.rs 4.5 ms ± 0.6 ms
Day 4 Problem 4 day4.rs 2.7 ms ± 0.4 ms
Day 5 Problem 5 day5.rs 2.9 ms ± 0.6 ms
Day 6 Problem 6 day6.rs 5.8 ms ± 0.4 ms
Day 7 Problem 7 day7.rs 13.2 ms ± 0.6 ms
Day 8 Problem 8 day8.rs 2.8 ms ± 0.5 ms
Day 9 Problem 9 day9.rs 216.0 ms ± 3.8 ms

Install Rust

If you don't have Rust installed (how dare you) just run this:

curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

If you are not using a Unix-like OS, check the instructions here

Usage

Clone

git clone https://github.com/MrRobb/advent-of-code-2019.git
cd advent-of-code-2019

Build

cargo build

Run

Run all

cargo run

Run a specific day

cargo run --bin day1

Benchmarks

Benchmark #1: target/release/day1
  Time (mean ± σ):       2.7 ms ±   0.5 ms    [User: 0.9 ms, System: 0.7 ms]
  Range (min … max):     2.2 ms …   6.6 ms    450 runs

Benchmark #2: target/release/day2
  Time (mean ± σ):       5.2 ms ±   0.5 ms    [User: 3.2 ms, System: 0.8 ms]
  Range (min … max):     4.4 ms …   7.0 ms    322 runs

Benchmark #3: target/release/day3
  Time (mean ± σ):       4.5 ms ±   0.6 ms    [User: 2.5 ms, System: 0.8 ms]
  Range (min … max):     3.9 ms …   7.5 ms    305 runs

Benchmark #4: target/release/day4
  Time (mean ± σ):       2.7 ms ±   0.4 ms    [User: 0.8 ms, System: 0.7 ms]
  Range (min … max):     2.2 ms …   4.7 ms    447 runs

Benchmark #5: target/release/day5
  Time (mean ± σ):       2.9 ms ±   0.6 ms    [User: 1.0 ms, System: 0.8 ms]
  Range (min … max):     2.3 ms …   6.3 ms    412 runs

Benchmark #6: target/release/day6
  Time (mean ± σ):       5.8 ms ±   0.4 ms    [User: 3.7 ms, System: 0.9 ms]
  Range (min … max):     5.3 ms …   7.3 ms    290 runs

Benchmark #7: target/release/day7
  Time (mean ± σ):      13.2 ms ±   0.6 ms    [User: 10.9 ms, System: 1.0 ms]
  Range (min … max):    12.3 ms …  15.0 ms    180 runs

Benchmark #8: target/release/day8
  Time (mean ± σ):       2.8 ms ±   0.5 ms    [User: 1.0 ms, System: 0.7 ms]
  Range (min … max):     2.3 ms …   5.2 ms    489 runs

Benchmark #9: target/release/day9
  Time (mean ± σ):     216.0 ms ±   3.8 ms    [User: 212.0 ms, System: 1.8 ms]
  Range (min … max):   210.0 ms … 229.1 ms    100 runs

About

Rust solutions of Advent of Code 2019

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages