https://github.com/guanshiyin28/primitive-list-doubly-linked-list
Primitive List Doubly Linked List (C++)
https://github.com/guanshiyin28/primitive-list-doubly-linked-list
cpp linked-list list-double primitive
Last synced: 10 months ago
JSON representation
Primitive List Doubly Linked List (C++)
- Host: GitHub
- URL: https://github.com/guanshiyin28/primitive-list-doubly-linked-list
- Owner: guanshiyin28
- License: apache-2.0
- Created: 2024-12-27T00:49:19.000Z (12 months ago)
- Default Branch: master
- Last Pushed: 2025-01-25T19:06:10.000Z (11 months ago)
- Last Synced: 2025-01-25T19:20:23.983Z (11 months ago)
- Topics: cpp, linked-list, list-double, primitive
- Language: C++
- Homepage:
- Size: 23.4 KB
- Stars: 6
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Security: SECURITY.md
Awesome Lists containing this project
README
# Primitive List Doubly Linked List
This repository aims to provide a comprehensive starting point for understanding and implementing two fundamental data structures: a Primitive List and a Doubly Linked List. These data structures are implemented in C++ and serve as a great introduction to list manipulation and linked list concepts for beginners and intermediate programmers.
## Purpose of This Repository
### Primitive List
A Primitive List is a basic data structure that allows storing a collection of elements in a sequential manner. This repository provides examples of how to create, manipulate, and perform common operations on primitive lists in C++.
### Doubly Linked List
A Doubly Linked List is a more advanced data structure where each node contains a reference to both the next and the previous node in the sequence. This allows for more efficient insertion and deletion operations compared to a singly linked list. This repository includes examples of how to implement and manipulate doubly linked lists in C++.
## Demonstration
### Primitive List Example
```cpp
#include
#include "PrimitiveList.h"
int main() {
PrimitiveList list;
list.append(1);
list.append(2);
list.append(3);
list.display(); // Output: 1 2 3
return 0;
}
```
### Doubly Linked List Example
```cpp
#include
#include "DoublyLinkedList.h"
int main() {
DoublyLinkedList list;
list.append(1);
list.append(2);
list.append(3);
list.display(); // Output: 1 2 3
return 0;
}
```
## Features
- Basic implementation of Primitive List
- Advanced implementation of Doubly Linked List
- Examples of common operations (insertion, deletion, traversal)
- Well-documented code for easy understanding
## Technologies Used
- C++
- GitHub for version control
## Project Setup
1. **Clone the repository:**
```bash
git clone https://github.com/your-username/Primitive-List-Doubly-Linked-List.git
```
2. **Navigate to the project directory:**
```bash
cd Primitive-List-Doubly-Linked-List
```
## Steps to Run
1. **Compile the code using a C++ compiler:**
```bash
g++ -o main main.cpp
```
2. **Run the executable:**
```bash
./main
```
## License
This project is licensed under the Apache-2.0 License. See the [LICENSE](LICENSE) file for details.