{"id":22612236,"url":"https://github.com/ivanbgd/prefix-trie-matching-cpp","last_synced_at":"2025-03-28T23:44:37.490Z","repository":{"id":139677012,"uuid":"101184356","full_name":"ivanbgd/Prefix-Trie-Matching-CPP","owner":"ivanbgd","description":"Prefix Trie data structure with Pattern Matching, in C++","archived":false,"fork":false,"pushed_at":"2017-08-23T14:08:59.000Z","size":4,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-02-03T10:11:57.224Z","etag":null,"topics":["c-plus-plus","cpp","prefix-trie","trie","trie-structure","trie-tree","tries"],"latest_commit_sha":null,"homepage":null,"language":"C++","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/ivanbgd.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-08-23T13:39:42.000Z","updated_at":"2017-09-22T14:49:19.000Z","dependencies_parsed_at":null,"dependency_job_id":"7bc72ab3-eeee-4bbb-bcaa-a27745aaa7f2","html_url":"https://github.com/ivanbgd/Prefix-Trie-Matching-CPP","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/ivanbgd%2FPrefix-Trie-Matching-CPP","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanbgd%2FPrefix-Trie-Matching-CPP/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanbgd%2FPrefix-Trie-Matching-CPP/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivanbgd%2FPrefix-Trie-Matching-CPP/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ivanbgd","download_url":"https://codeload.github.com/ivanbgd/Prefix-Trie-Matching-CPP/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246117690,"owners_count":20726068,"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":["c-plus-plus","cpp","prefix-trie","trie","trie-structure","trie-tree","tries"],"created_at":"2024-12-08T17:11:30.657Z","updated_at":"2025-03-28T23:44:37.472Z","avatar_url":"https://github.com/ivanbgd.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Prefix-Trie-Matching-CPP\nPrefix Trie data structure with Pattern Matching, in C++\n\nhttps://en.wikipedia.org/wiki/Trie\n\nIt has been made to work with alphabet \"A, C, G, T\" for human genome, but the alphabet can be easily modified.\n\nThis example collects the so called Reads (samples), which is a collection of strings, named \"Patterns\", and we want to match them against a reference genome named \"Text\".\nThe algorithm finds whether any string in Patterns matches a prefix of Text.\nIt is able to handle cases where one of the patterns is a prefix of another pattern.\n\nThis example uses the next input and output formats:\nInput Format: The first line of the input contains a string Text, the second line contains an integer 𝑛,\neach of the following 𝑛 lines contains a pattern from Patterns = {𝑝1, . . . , 𝑝𝑛}.\nOutput Format: All starting positions in Text where a string from Patterns appears as a substring in\nincreasing order (assuming that Text is a 0-based array of symbols). If more than one pattern appears starting at position 𝑖, outputs 𝑖 once.\n\nSample 1:\nInput:\nAAA\n1\nAA\nOutput:\n0 1\nExplanation: The pattern AA appears at positions 0 and 1. Note that these two occurrences of the pattern overlap.\n\nSample 2:\nInput:\nACATA\n3\nAT\nA\nAG\nOutput:\n0 2 4\nExplanation: Text contains occurrences of A at positions 0, 2, and 4, as well as an occurrence of AT at position 2.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivanbgd%2Fprefix-trie-matching-cpp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fivanbgd%2Fprefix-trie-matching-cpp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivanbgd%2Fprefix-trie-matching-cpp/lists"}