{"id":25080165,"url":"https://github.com/sitetester/recipe-stats-calculator","last_synced_at":"2025-04-01T04:39:35.908Z","repository":{"id":57632455,"uuid":"287681318","full_name":"sitetester/recipe-stats-calculator","owner":"sitetester","description":null,"archived":false,"fork":false,"pushed_at":"2024-08-21T13:35:28.000Z","size":42,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-07T03:18:11.343Z","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":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sitetester.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-08-15T05:05:27.000Z","updated_at":"2024-08-21T13:35:31.000Z","dependencies_parsed_at":"2022-08-31T16:31:19.173Z","dependency_job_id":null,"html_url":"https://github.com/sitetester/recipe-stats-calculator","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sitetester%2Frecipe-stats-calculator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sitetester%2Frecipe-stats-calculator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sitetester%2Frecipe-stats-calculator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sitetester%2Frecipe-stats-calculator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sitetester","download_url":"https://codeload.github.com/sitetester/recipe-stats-calculator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246586099,"owners_count":20801026,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":"2025-02-07T03:18:25.420Z","updated_at":"2025-04-01T04:39:35.872Z","avatar_url":"https://github.com/sitetester.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"Recipe Stats Calculator\n====\n\nThis program processes an automatically generated JSON file with recipe data and calculate some stats.\n\nGiven\n-----\n\n_Important notes_\n\n1. Property value `\"delivery\"` always has the following format: \"{weekday} {h}AM - {h}PM\", i.e. \"Monday 9AM - 5PM\"\n2. The number of distinct postcodes is lower than `1M`, one postcode is not longer than `10` chars.\n3. The number of distinct recipe names is lower than `2K`, one recipe name is not longer than `100` chars.\n\nFunctional Requirements\n------\n\n1. Count the number of unique recipe names.\n2. Count the number of occurrences for each unique recipe name (alphabetically ordered by recipe name).\n3. Find the postcode with most delivered recipes.\n4. Count the number of deliveries to postcode `10120` that lie within the delivery time between `10AM` and `3PM`, examples _(`12AM` denotes midnight)_:\n    - `NO` - `9AM - 2PM`\n    - `YES` - `10AM - 2PM`\n5. List the recipe names (alphabetically ordered) that contain in their name one of the following words:\n    - Potato\n    - Veggie\n    - Mushroom\n\nNon-functional Requirements\n--------\n\n1. The application is packaged with [Docker](https://www.docker.com/).\n2. Setup scripts are provided.\n3. The submission is provided as a `CLI` application.\n4. The expected output is rendered to `stdout`. Make sure to render only the final `json`. If you need to print additional info or debug, pipe it to `stderr`.\n5. It should be possible to (implementation is up to you):  \n    a. provide a custom fixtures file as input  \n    b. provide custom recipe names to search by (functional reqs. 5)  \n    c. provide custom postcode and time window for search (functional reqs. 4)  \n\nExpected output\n---------------\n\nGenerate a JSON file of the following format:\n\n```json5\n{\n    \"unique_recipe_count\": 15,\n    \"count_per_recipe\": [\n        {\n            \"recipe\": \"Mediterranean Baked Veggies\",\n            \"count\": 1\n        },\n        {\n            \"recipe\": \"Speedy Steak Fajitas\",\n            \"count\": 1\n        },\n        {\n            \"recipe\": \"Tex-Mex Tilapia\",\n            \"count\": 3\n        }\n    ],\n    \"busiest_postcode\": {\n        \"postcode\": \"10120\",\n        \"delivery_count\": 1000\n    },\n    \"count_per_postcode_and_time\": {\n        \"postcode\": \"10120\",\n        \"from\": \"11AM\",\n        \"to\": \"3PM\",\n        \"delivery_count\": 500\n    },\n    \"match_by_name\": [\n        \"Mediterranean Baked Veggies\", \"Speedy Steak Fajitas\", \"Tex-Mex Tilapia\"\n    ]\n}\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsitetester%2Frecipe-stats-calculator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsitetester%2Frecipe-stats-calculator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsitetester%2Frecipe-stats-calculator/lists"}