Skip to content

Repository files navigation

DSA Code Repository

Welcome to the DSA Code Repository! This repository contains implementations of various Data Structures and Algorithms in multiple programming languages. It is designed to help students, programmers, and coding enthusiasts learn and practice DSA concepts effectively.

📌 Table of Contents

📖 About

This repository serves as a comprehensive collection of important DSA problems, solutions, and explanations. It is structured to help beginners get started and allow experienced coders to refine their skills.

💻 Languages Covered

  • C
  • C++

📚 Topics Covered

  • Basic Algorithms: Sorting, Searching, Recursion, Backtracking
  • Data Structures:
    • Arrays (insert, delete, search, traverse)
    • Linked Lists (singly, doubly, circular) with head & tail pointers
    • Stacks (array-based and linked list-based)
    • Queues (linear, circular, deque, priority queue)
    • Trees (Binary Search Tree with traversals)
    • Graphs (representation, BFS, DFS)
    • Hash Tables (chaining and linear probing)
    • Heaps (max heap, min heap)
  • Expression Handling:
    • Conversions: Infix ↔ Postfix ↔ Prefix (all 6 conversions)
    • Evaluation: Infix, Postfix, and Prefix expression evaluation
  • Advanced Topics: Dynamic Programming, Greedy Algorithms, Graph Algorithms (BFS, DFS, Dijkstra's, Kruskal's, Prim's), Bit Manipulation
  • Competitive Programming: Frequently asked DSA questions in coding interviews

📂 Repository Structure

DSA-Codes/
├── arrays/                       # Array operations (insert, delete, search, traverse)
├── linked_lists/                 # All types of linked lists
│   ├── singly_linked_list.c     # Singly linked list with head & tail pointers
│   ├── doubly_linked_list.c     # Doubly linked list with head & tail pointers
│   ├── circular_linked_list.c   # Circular linked list implementation
│   ├── stack_using_linked_list.c # Stack implementation using linked list
│   └── queue_using_linked_list.c # Queue implementation using linked list
├── stack/                        # Stack implementations and applications
│   ├── stack.c                   # Array-based stack
│   ├── expression_conversion.c  # Infix, Prefix, Postfix conversions
│   └── expression_evaluation.c  # Expression evaluation (all formats)
├── queue/                        # Various queue implementations
│   ├── linear_queue.c            # Linear queue
│   ├── circular_queue.c          # Circular queue
│   ├── doubly_ended_queue.c     # Deque (insert/delete from both ends)
│   └── priority_queue.c          # Priority queue implementation
├── trees/                        # Binary Search Tree (BST) with traversals
├── graphs/                       # Graph representation, BFS, DFS
├── sorting/                      # Bubble, Selection, Insertion, Merge, Quick Sort
├── searching/                    # Linear Search, Binary Search
├── recursion/                    # Factorial, Fibonacci, Tower of Hanoi, GCD
├── hashing/                      # Hash tables with chaining and linear probing
├── heap/                         # Max heap, Min heap, Heap Sort
├── strings/                      # String operations, pattern matching, palindrome
├── bit_manipulation/             # Bit operations and manipulation tricks
├── Dynamic_memory_allocation/    # malloc, calloc, realloc examples
└── README.md                     # This file

Each topic folder contains:

  • Working C code examples with interactive menus
  • Individual README.md with compilation instructions
  • Time complexity analysis and algorithm explanations
  • Real-world applications and use cases

🚀 How to Use

  1. Clone the repository:

    git clone https://github.com/DigarSingh/dsa-codes.git
  2. Navigate to the directory:

    cd dsa-codes
  3. Open the files in your preferred code editor and run the code.

🤝 Contributing

Contributions are always welcome! Follow these steps to contribute:

  1. Fork the repository.

  2. Create a new branch:

    git checkout -b feature-branch
  3. Add your code and commit changes:

    git commit -m "Added new DSA solution"
  4. Push to your forked repository:

    git push origin feature-branch
  5. Open a Pull Request.


Happy Coding! 🚀

About

Welcome to the DSA Code Repository! This repository contains implementations of various Data Structures and Algorithms in multiple programming languages. It is designed to help students, programmers, and coding enthusiasts learn and practice DSA concepts effectively.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages