- Pop some popcorn 🍿 (or whatever you enjoy 🍭 🍾 🥛 🍷 🍹 🍫 🍺)
- Fork
- Write a solution, in the language of your choice. Example:
vim day-03/solutions/super-optimized.py - Test your solution.
cd days/day03
../../languages/python.sh input.txt output.txt solutions/super-optimized.py- Add the test to
day03/test.sh, to let the CI know how to test your solution. - Make a Pull Request to the
mainbranch. - One of the maintainers will merge when the tests pass!
- Remember to have fun 🎉
- Add the language you want to the
Dockerfile - Add a language test-script in
languages/<new-language>.sh - Add an example solution in
days/day-00-example/solutions/example.<new-language> - Make a PR to
main-branch. - One of the maintainers will do
make docker.buildandmake docker.pushand merge your PR on his machine ASAP 🏎️
Every solution gets the input.txt-file delivered to stdin using cat, and whatever is written to stdout is compared for equality against output.txt using diff. This is identical for every language.
#!/usr/bin/env bash
cat input.txt | <solution-in-any-language> | diff - output.txtSee day-00-example/solutions/, for examples on how to read from stdin and how to write to stdout in different languages.