{"id":18822898,"url":"https://github.com/salma-mamdoh/rsvector","last_synced_at":"2025-10-27T04:13:09.932Z","repository":{"id":128887082,"uuid":"575834711","full_name":"Salma-Mamdoh/RSVector","owner":"Salma-Mamdoh","description":"Our Project for Object Oriented Programming  Course taken during Winter 2022 semester","archived":false,"fork":false,"pushed_at":"2023-07-12T01:05:15.000Z","size":755,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-12-30T04:18:39.304Z","etag":null,"topics":["backtracking-algorithm","cpp","data-structures","exception-handling","filesystem","oop","problem-solving","recursion"],"latest_commit_sha":null,"homepage":"","language":"C++","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/Salma-Mamdoh.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-12-08T12:05:39.000Z","updated_at":"2024-05-07T15:43:18.000Z","dependencies_parsed_at":"2024-11-08T00:52:04.539Z","dependency_job_id":"43fc2a36-fdec-441f-a2b6-13cb656715a5","html_url":"https://github.com/Salma-Mamdoh/RSVector","commit_stats":null,"previous_names":["salma-mamdoh/oop---assignment-3"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Salma-Mamdoh%2FRSVector","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Salma-Mamdoh%2FRSVector/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Salma-Mamdoh%2FRSVector/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Salma-Mamdoh%2FRSVector/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Salma-Mamdoh","download_url":"https://codeload.github.com/Salma-Mamdoh/RSVector/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239758889,"owners_count":19692041,"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":["backtracking-algorithm","cpp","data-structures","exception-handling","filesystem","oop","problem-solving","recursion"],"created_at":"2024-11-08T00:52:02.326Z","updated_at":"2025-10-27T04:13:04.885Z","avatar_url":"https://github.com/Salma-Mamdoh.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003c!DOCTYPE html\u003e \u003chtml\u003e \u003chead\u003e  \u003c/head\u003e \u003cbody\u003e \u003ch1\u003eRSVector Class\u003c/h1\u003e \u003ch2\u003eIntroduction\u003c/h2\u003e \u003cp\u003eWelcome to the RSVector Class repository! This repository contains the implementation of the RSVector class, which is a dynamic array template class with additional functionality compared to the standard std::vector class. In addition to the RSVector class, this repository also includes implementations of other popular data structures such as set, map, and stack.\u003c/p\u003e \u003cp\u003eThe implementations of these data structures use object-oriented programming (OOP) concepts such as exceptions and templates. The functionalities for these data structures include push, pop, insert, and erase.\u003c/p\u003e \u003cp\u003eFurthermore, this repository includes some problem-solving examples on the topic of backtracking, which is a widely used algorithmic technique for solving problems by trying out all possible paths and finding the one that satisfies the given constraints.\u003c/p\u003e \u003ch2\u003ePrivate Members\u003c/h2\u003e \u003cul\u003e \u003cli\u003edata: A pointer to the dynamically allocated array that stores the elements of the vector.\u003c/li\u003e \u003cli\u003esize: The number of elements currently in the vector.\u003c/li\u003e \u003cli\u003ecapacity: The total capacity of the allocated array.\u003c/li\u003e \u003c/ul\u003e \u003ch2\u003ePublic Members\u003c/h2\u003e \u003ch3\u003eConstructors and Big 4\u003c/h3\u003e \u003cul\u003e \u003cli\u003eRSVector(int): Initializes the vector with a specific capacity. No content is added, and the size is 0.\u003c/li\u003e \u003cli\u003eRSVector(T*, int): Initializes the vector with n items from an array.\u003c/li\u003e \u003cli\u003eRSVector(const RSVector\u0026): Initializes the vector with a copy of another vector.\u003c/li\u003e \u003cli\u003e~RSVector(): Deletes the allocated memory.\u003c/li\u003e \u003cli\u003eRSVector\u0026 operator=(const RSVector\u0026): Copy assignment.\u003c/li\u003e \u003cli\u003eRSVector\u0026 operator=(RSVector\u0026\u0026): Move assignment.\u003c/li\u003e \u003c/ul\u003e \u003ch3\u003eAccess Operations\u003c/h3\u003e \u003cul\u003e \u003cli\u003eT\u0026 operator[](int): Accesses an item by reference. Throws an exception if out of range.\u003c/li\u003e \u003c/ul\u003e \u003ch3\u003eModifying Operations\u003c/h3\u003e \u003cul\u003e \u003cli\u003eint push_back(T): Adds an item to the end of the vector and returns the number of items. Increases capacity if needed.\u003c/li\u003e \u003cli\u003eT pop_back(): Removes and returns the last element in the vector.\u003c/li\u003e \u003cli\u003evoid erase(iterator): Removes an item at an iterator. Throws an exception if invalid iterator.\u003c/li\u003e \u003cli\u003evoid erase(iterator1, iterator2): Removes items between iterator1 and iterator2. Throws an exception if any iterator is outside the range.\u003c/li\u003e \u003cli\u003evoid clear(): Deletes all vector content.\u003c/li\u003e \u003cli\u003evoid insert(iterator, T): Inserts an item at an iterator. Throws an exception if invalid iterator.\u003c/li\u003e \u003c/ul\u003e \u003ch3\u003eIterators\u003c/h3\u003e \u003cul\u003e \u003cli\u003eiterator begin(): Returns an iterator to the beginning of the vector.\u003c/li\u003e \u003cli\u003eiterator end(): Returns an iterator to the end of the vector.\u003c/li\u003e \u003c/ul\u003e \u003ch3\u003eComparison Operations\u003c/h3\u003e \u003cul\u003e \u003cli\u003ebool operator==(const RSVector\u0026): Returns true if the vectors are equal.\u003c/li\u003e \u003cli\u003ebool operator\u003c(const RSVector\u0026): Compares item by item and returns true if the first different item in this is less than in the other.\u003c/li\u003e \u003c/ul\u003e \u003ch3\u003eCapacity Operations\u003c/h3\u003e \u003cul\u003e \u003cli\u003eint size() const: Returns the current size of the vector.\u003c/li\u003e \u003cli\u003eint capacity() const: Returns the size of the currently allocated array.\u003c/li\u003e \u003cli\u003eint resize(): Relocates to a bigger space.\u003c/li\u003e \u003cli\u003ebool empty(): Returns true if the size is 0.\u003c/li\u003e \u003c/ul\u003e \u003ch3\u003eFriends\u003c/h3\u003e \u003cul\u003e \u003cli\u003efriend ostream\u0026 operator\u003c\u003c(ostream\u0026 out, RSVector\u003cT\u003e): Overloads the \u003c\u003c operator to print the vector.\u003c/li\u003e \u003c/ul\u003e  \u003ch2\u003eTesting\u003c/h2\u003e \u003cp\u003eMultiple client programs should be written to test the class templates on different types. The tests should cover all member functions and edge cases, such as adding and removing elements, resizing, and copying. This will ensure that the implementations are correct and robust.\u003c/p\u003e \u003ch2\u003eConclusion\u003c/h2\u003e \u003cp\u003eThe RSVector Class repository is intended for anyone who wants to learn more about OOP, data structures, and problem-solving. Whether you're a beginner or an experienced programmer, you'll find useful information and examples in this repository. We encourage you to explore the code and solutions, and to experiment with the data structures and algorithms to deepen your understanding and improve your skills.\u003c/p\u003e \u003c/body\u003e \u003c/html\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsalma-mamdoh%2Frsvector","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsalma-mamdoh%2Frsvector","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsalma-mamdoh%2Frsvector/lists"}