Skip to content

okz12/adventofcode2020

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

72 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Advent of Code 2020

Christmas flavoured coding puzzles

See challenge descriptions here: https://adventofcode.com/2020

Code in Python 3.8 (I've used math.prod, walrus operators etc. on some days).


Post-completion reflection

Completed 25/25 (also hit day 25 leaderboard with position #850).

What I loved:

Good spread of problems with no interconnectivity (debugging intcode every other day during AoC2019 was draining).

What I hated:

Being stuck on 13 for an hour trying to compute a modulus with remainder efficiently before finding out about Chinese Remainder Theorem.

What I learnt:

New Python 3.8 features which I typically avoid for backward compatibility, better type hinting, dataclasses and practicing regex. The coolest trick I learnt was using complex numbers for 2D grid location (see days 12 and 24). This significantly improved my code as coordinates could be summed, multiplied and rotated using a built-in type with its operators.

About

Advent of Code 2020 (Python)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages