{"id":37206687,"url":"https://github.com/nlowe/aoc2021","last_synced_at":"2026-01-14T23:47:15.161Z","repository":{"id":57641646,"uuid":"425428937","full_name":"nlowe/aoc2021","owner":"nlowe","description":"Advent of Code 2021 Solutions","archived":false,"fork":false,"pushed_at":"2022-12-04T06:34:40.000Z","size":204,"stargazers_count":9,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-06-20T13:40:47.138Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nlowe.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-11-07T06:21:22.000Z","updated_at":"2023-08-15T17:07:58.000Z","dependencies_parsed_at":"2023-01-24T00:17:01.353Z","dependency_job_id":null,"html_url":"https://github.com/nlowe/aoc2021","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nlowe/aoc2021","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nlowe%2Faoc2021","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nlowe%2Faoc2021/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nlowe%2Faoc2021/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nlowe%2Faoc2021/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nlowe","download_url":"https://codeload.github.com/nlowe/aoc2021/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nlowe%2Faoc2021/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28439537,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T22:37:52.437Z","status":"ssl_error","status_checked_at":"2026-01-14T22:37:31.496Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-01-14T23:47:14.632Z","updated_at":"2026-01-14T23:47:15.153Z","avatar_url":"https://github.com/nlowe.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Advent of Code 2021\n\n[![](https://github.com/nlowe/aoc2021/workflows/CI/badge.svg)](https://github.com/nlowe/aoc2021/actions) [![Coverage Status](https://coveralls.io/repos/github/nlowe/aoc2021/badge.svg?branch=master)](https://coveralls.io/github/nlowe/aoc2021?branch=master) [![Go Report Card](https://goreportcard.com/badge/github.com/nlowe/aoc2021)](https://goreportcard.com/report/github.com/nlowe/aoc2021) [![License](https://img.shields.io/badge/license-MIT-brightgreen)](./LICENSE)\n\nSolutions for the 2021 Advent of Code\n\n## Building\n\nThis project makes use of Go 1.17.\n\n```bash\ngo mod download\ngo test ./...\n```\n\n## Running the Solutions\n\nTo run a solution, use the problem name followed by the path to an input file.\n\nFor example, to run problem 2a:\n\n```bash\n$ go run main.go 1 a\nAnswer: 1532\nTook 1.5586ms\n```\n\n## Adding New Solutions\n\nA generator program is included that makes templates for each day, automatically\ndownloading challenge input and updating the root command to add new subcommands\nfor each problem. Running `go generate` from the repo root will generate the\nfollowing for each day that is currently accessible:\n\n* `challenge/day\u003cN\u003e/import.go`: A \"glue\" file combining commands for both of the day's problems to simplify wiring up subcommands\n* `challenge/day\u003cN\u003e/a.go`: The main problem implementation, containing a cobra command `A` and the implementation `func a(*challenge.Input) int`\n* `challenge/day\u003cN\u003e/a_test.go`: A basic test template\n* `challenge/day\u003cN\u003e/b.go`: The main problem implementation, containing a cobra command `B` and the implementation `func b(*challenge.Input) int`\n* `challenge/day\u003cN\u003e/b_test.go`: A basic test template\n* `challenge/day\u003cN\u003e/input.txt`: The challenge input\n\nAdditionally, `challenge/cmd/cmd.go` will be regenerated to import and add all\nsubcommands.\n\nThis requires `goimports` be available on your `$PATH`. Additionally, you must be\nlogged into https://adventofcode.com in Chrome so the generator can use your session\ncookie to download challenge input.\n\nExisting solutions and challenge inputs will be skipped instead of regenerated.\n\n## License\n\nThese solutions are licensed under the MIT License.\n\nSee [LICENSE](./LICENSE) for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnlowe%2Faoc2021","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnlowe%2Faoc2021","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnlowe%2Faoc2021/lists"}