Skip to content

πŸŽ… Advent of Code in Kotlin

Notifications You must be signed in to change notification settings

ZhongXiLu/AdventOfCode

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Advent Of Code Kotlin CI

2024

Day Title Part 1 Part 2 Code
01 Historian Hysteria 🌟 🌟 Code
02 Red-Nosed Reports 🌟 🌟 Code
03 Mull It Over 🌟 🌟 Code
04 Ceres Search 🌟 🌟 Code
05 Print Queue 🌟 🌟 Code
06 Guard Gallivant 🌟 🌟 Code
07 Bridge Repair 🌟 🌟 Code
08 Resonant Collinearity 🌟 🌟 Code
09 Disk Fragmenter 🌟 🌟 Code
10 Hoof It 🌟 🌟 Code
11 Plutonian Pebbles 🌟 🌟 Code
12 Garden Groups 🌟 🌟* Code
13 Claw Contraption 🌟* 🌟 Code
14 Restroom Redoubt 🌟 🌟 Code
15 Warehouse Woes 🌟 🌟 Code
16 Reindeer Maze 🌟 Code

2023

Day Title Part 1 Part 2 Code
01 Trebuchet?! 🌟 🌟 Code
02 Cube Conundrum 🌟 🌟 Code
03 Gear Ratios 🌟 🌟 Code
04 Scratchcards 🌟 🌟 Code
05 If You Give A Seed A Fertilizer 🌟 🌟 Code
06 Wait For It 🌟 🌟 Code
07 Camel Cards 🌟 🌟 Code
08 Haunted Wasteland 🌟 🌟* Code
09 Mirage Maintenance 🌟 🌟 Code
10 Pipe Maze 🌟 🌟* Code

2022

Day Title Part 1 Part 2 Code
01 Calorie Counting 🌟 🌟 Code
02 Rock Paper Scissors 🌟 🌟 Code
03 Rucksack Reorganization 🌟 🌟 Code
04 Camp Cleanup 🌟 🌟 Code
05 Supply Stacks 🌟 🌟 Code
06 Tuning Trouble 🌟 🌟 Code
07 No Space Left On Device 🌟 🌟 Code
08 Treetop Tree House 🌟 🌟 Code
09 Rope Bridge 🌟 🌟 Code
10 Cathode-Ray Tube 🌟 🌟 Code
11 Monkey in the Middle 🌟 🌟* Code
12 Hill Climbing Algorithm 🌟 🌟 Code
13 Distress Signal 🌟 🌟 Code
14 Regolith Reservoir 🌟 🌟 Code
15 Beacon Exclusion Zone 🌟 🌟* Code
16 Proboscidea Volcanium 🌟* 🌟* Code
17 Pyroclastic Flow 🌟 🌟 Code
18 Boiling Boulders 🌟 🌟 Code
19 Not Enough Minerals 🌟* 🌟 Code
20 Grove Positioning System 🌟 🌟 Code
21 Monkey Math 🌟 🌟 Code
22 Monkey Map 🌟 🌟 Code
23 Unstable Diffusion 🌟 🌟 Code
24 Blizzard Basin 🌟 🌟 Code
25 Full of Hot Air 🌟 🌟 Code

2021

Day Title Part 1 Part 2 Code
01 Sonar Sweep 🌟 🌟 Code
02 Dive! 🌟 🌟 Code
03 Binary Diagnostic 🌟 🌟 Code
04 Giant Squid 🌟 🌟 Code
05 Hydrothermal Venture 🌟 🌟 Code
06 Lanternfish 🌟 🌟* Code
07 The Treachery of Whales 🌟 🌟 Code
08 Seven Segment Search 🌟 🌟 Code
09 Smoke Basin 🌟 🌟 Code
10 Syntax Scoring 🌟 🌟 Code
11 Dumbo Octopus 🌟 🌟 Code

*with some hints from Reddit πŸ˜‡

How to add a new day and how to run it

  1. Create a new class in the right package: aoc.years.year<year>.Day<day>:

    @Year2022
    class Day25 : Day() {
    
        override fun solvePart1(input: List<String>): Any {
            return ""
        }
    
        override fun solvePart2(input: List<String>): Any {
            return ""
        }
    
    }
  2. Store the input in resources/year<year>/Day<day>.txt

  3. Then you can run the DayRunner class with the year and day as arguments (or without any arguments to run every day):

     aoc.DayRunnerKt 2022 25