Skip to content

theanujsinha01/DSA-in-CPP

Repository files navigation

DSA-in-CPP

Data Structures and Algorithms in C++

Welcome to the Data Structures and Algorithms (DSA) repository! This repo contains various implementations of common data structures and algorithms in C++. Each algorithm and data structure has been implemented in a beginner-friendly way to help you understand and practice DSA concepts.


Table of Contents


Introduction

Data Structures and Algorithms (DSA) form the foundation of efficient problem-solving in computer science. Mastering DSA is essential for tackling complex problems, optimizing code, and preparing for technical interviews.

In this repository, you'll find:

  • Basic to advanced DSA concepts.
  • Code written in C++ with comments for easy understanding.
  • Examples and test cases to see how each algorithm works in action.

Getting Started

Prerequisites

  • Basic knowledge of C++.
  • A C++ compiler (like GCC, Clang, or Visual Studio).
  • Familiarity with Git for cloning the repository (optional).

Installation

  1. Clone the repository:
    git clone https://github.com/yourusername/DSA-in-Cpp.git
  2. Navigate to the directory:
    cd DSA-in-Cpp
  3. Compile and run a program:
    g++ filename.cpp -o filename
    ./filename

Data Structures

  • Arrays
  • Linked Lists
  • Stacks
  • Queues
  • Trees
  • Graphs
  • Hash Tables
  • Sliding Window
  • Greedy
  • Recursion

Algorithms

  • Sorting Algorithms

    • Bubble Sort –
    • Merge Sort –
    • Quick Sort –
    • Selection Sort-
    • Insertion Sort-
  • Searching Algorithms

    • Binary Search –
    • Linear Search –
  • Graph Algorithms

    • Breadth-First Search (BFS) – bfs.cpp
    • Depth-First Search (DFS) – dfs.cpp
  • Dynamic Programming

    • Fibonacci Sequence –
    • Knapsack Problem –

How to Contribute

We welcome contributions to improve and expand this repository! To contribute:

  1. Fork this repository.
  2. Create a new branch:
    git checkout -b feature/YourFeatureName
  3. Make your changes and commit:
    git commit -m "Add your feature"
  4. Push to your branch:
    git push origin feature/YourFeatureName
  5. Create a pull request on GitHub.

Resources

Happy Coding! 🎉


About

Welcome to the Data Structures and Algorithms (DSA) repository! This repo contains various implementations of common data structures and algorithms in C++. Each algorithm and data structure has been implemented in a beginner-friendly way to help you understand and practice DSA concepts.

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages