Skip to content

kilian-kier/AdventOfCode22

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AoC++

My solutions for Advent Of Code 2022 using the C++ Standard Library

Why C++

Recently I've been using C++ primarily for competitive programming challenges. Mainly because this year I qualified for the national Olympiad in Informatics and only C++ was allowed there. Therefore I've trained many of these problems in C++. But for example the eval() function from Python would have been very helpful in parsing day 13... Despite this, I was able to work with it effectively but next year I'll probably switch to Python so I can focus on solving the problems and not on parsing.

Usage

mkdir build && cd build
cmake ..
make
./AdventOfCode2022

Directory Hierarchy

|—— .gitignore
|—— CMakeLists.txt
|—— README.md
|—— include
|    |—— Converter.h
|    |—— Day{$day}Solver.h
|    |—— InputHelper.h
|    |—— Solver.h
|    |—— Utils.h
|    |—— main.h
|—— src
|    |—— Day{$day}
|        |—— Day{$day}Solver.cpp
|        |—— example.txt
|        |—— input.txt
|        |—— output.txt
|    |—— Helper
|        |—— Converter.cpp
|        |—— InputHelper.cpp
|        |—— Solver.cpp
|        |—— Utils.cpp
|    |—— main.cpp

Some stats

Fastests execution (on my Laptop)

  • Day 1: <1ms
  • Day 2: <1ms
  • Day 6: <1ms
  • Day 10: <1ms

Slowest execution (on my Laptop)

  • Day 16: ~110s
  • Day 15: ~30s
  • Day 19: ~25s
  • Day 20: ~3s

Fastest solving

  • Day 6: solved after 11 minutes
  • Day 1: solved after 15 minutes

Slowest solving

  • Day 16: >24h
  • Day 20: >24h

About

My solutions for this year's Advent of Code

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published