{"id":16855095,"url":"https://github.com/stageguard/datastructurecurriculumdesign","last_synced_at":"2025-06-19T07:39:27.118Z","repository":{"id":126712770,"uuid":"441622659","full_name":"StageGuard/DataStructureCurriculumDesign","owner":"StageGuard","description":"Data structure curriculum design for term 1 grade 2.","archived":false,"fork":false,"pushed_at":"2021-12-25T07:11:09.000Z","size":18,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-18T11:11:51.798Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/StageGuard.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":"2021-12-25T06:54:28.000Z","updated_at":"2021-12-25T07:11:11.000Z","dependencies_parsed_at":"2023-06-18T13:42:21.291Z","dependency_job_id":null,"html_url":"https://github.com/StageGuard/DataStructureCurriculumDesign","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/StageGuard/DataStructureCurriculumDesign","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StageGuard%2FDataStructureCurriculumDesign","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StageGuard%2FDataStructureCurriculumDesign/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StageGuard%2FDataStructureCurriculumDesign/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StageGuard%2FDataStructureCurriculumDesign/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/StageGuard","download_url":"https://codeload.github.com/StageGuard/DataStructureCurriculumDesign/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StageGuard%2FDataStructureCurriculumDesign/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260709767,"owners_count":23050266,"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":"2024-10-13T13:58:27.770Z","updated_at":"2025-06-19T07:39:22.092Z","avatar_url":"https://github.com/StageGuard.png","language":"C++","readme":"## DataStructureCurriculumDesign\n### A Double-linked list.\n\nClass definition\n\n```c++\nclass DLinkedList\u003cT\u003e {\n    bool isEmpty(); // return if empty\n    bool add(T); // add element at the tail\n    bool add(uint32_t, T); // add element at the specific index\n    T set(uint32_t, T); // set element at the specific index\n    T remove(uint32_t); // remove element at the specific index\n    bool remove(T); // remove element that equals it\n    T get(uint32_t); // get element at specific index\n    clear(); // clear all elements\n    traverse(Function); // traverse list with lambda\n    traverse_reversed(Function); // traverse list reversed\n    contains(T); // return if list contains it\n    indexOf(T); // return first index of it or -1 if not exists\n    lastIndexOf(T); // return last index of it or -1 if not exists\n    size(); // return size\n    class Iterator {\n        Iterator begin(); // list head\n        Iterator end(); // list tail\n    };\n    iter(); // return the iterator\n    riter(); // return the reversed iterator\n};\n\n```\n\nBecause the `DLinkedList` implements `iterator`, so it supports some STL container operations.\n\n```c++\nauto iter = list -\u003e iter();\n// for each\nfor_each(iter.begin(), iter.end(), [\u0026](int e) {\n    cout \u003c\u003c e \u003c\u003c \" \";\n});\n// sum\nauto sum = accumulate(iter.begin(), iter.end(), 0);\n```","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstageguard%2Fdatastructurecurriculumdesign","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstageguard%2Fdatastructurecurriculumdesign","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstageguard%2Fdatastructurecurriculumdesign/lists"}