Skip to content

hamza4600/dsa_in-C

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Basic Data Structures in C

This repository contains basic data structures implemented in C. The data structures are implemented using arrays and linked lists. The data structures are:

  • Stack
  • Queue
  • Linked List
  • Binary Search Tree
  • Graph
  • Hash Table

Stack

A stack is a data structure that stores data in a Last-In-First-Out (LIFO) manner. The stack is implemented using an array. The following operations are supported:

  • Push
  • Pop
  • Peek
  • Is Empty
  • Is Full

Queue

A queue is a data structure that stores data in a First-In-First-Out (FIFO) manner. The queue is implemented using an array. The following operations are supported:

  • Enqueue
  • Dequeue
  • Peek
  • Is Empty
  • Is Full

Linked List

A linked list is a data structure that stores data in a sequential manner. The linked list is implemented using a linked list. The following operations are supported:

  • Insert
  • Delete
  • Search
  • Is Empty

Binary Search Tree

A binary search tree is a data structure that stores data in a sorted manner. The binary search tree is implemented using a linked list. The following operations are supported:

  • Insert
  • Delete
  • Search
  • Is Empty

Max Heap

A max heap is a data structure that stores data in a sorted manner. The max heap is implemented using an nodes. The following operations are supported:

  • Insert
  • Delete
  • Search
  • Find Min
  • Root Node
  • Print In Order (Left, Root, Right)
  • Print Pre Order (Root, Left, Right)
  • Print Post Order (Left, Right, Root)

Search and Sorting Algorithms

The following search and sorting algorithms are implemented:

  • Linear Search
  • Binary Search
  • Bubble Sort
  • Insertion Sort
  • Selection Sort
  • Merge Sort
  • Quick Sort
  • Heap Sort

Hash Table

A hash table is a data structure that stores data in a hashed manner. The hash table is implemented using an array. The following operations are supported:

  • Insert
  • Delete
  • Search
  • Delete All

Graph

A graph is a data structure that stores data in a node and edge manner. The graph is implemented using a linked list. The following operations are supported:

  • Insert Node
  • Insert Edge
  • Delete Node
  • Delete Edge
  • Search Node