# C++ Programming Examples on Data-Structures

## 1. C++ Programming examples on “Hashing”

Hashing is a conversion of large keys into small keys by using hash functions. Function that transforms a key into a table index is called a hash function. Hash tree is a persistent data structure that can be used to implement sets and maps, intended to replace hash tables in purely functional programming. Rolling hash allows an algorithm to calculate the hash value without having the rehash in the given string. The following section demonstrates the implementation of hash tables using singly linked lists, binary trees, list heads, doubly linked lists, double hashing, linear and quadratic probing. It also explains the hash tree, hash list, min hash, rolling and distributed hash table.

C++ Program to Implement Hash Tables C++ Program to Implement Hash Tables chaining with Singly Linked Lists C++ Program to Implement Hash Tables Chaining with Binary Trees C++ Program to Implement Hash Tables Chaining with Doubly Linked Lists C++ Program to Implement Hash Tables Chaining with List Heads C++ Program to Implement Hash Tables with Linear Probing C++ Program to Implement Hash Tables with Quadratic Probing C++ Program to Implement Hash Tables with Double Hashing C++ Program to Implement Hash Tree C++ Program to Implement Hash List C++ Program to Implement Hash Tree C++ Program to Implement prefix Hash Tree C++ Program to Implement Rolling Hash C++ Program to Implement CountMinSketch C++ Program to Implement Min Hash C++ Program to Implement Distributed Hash table |

## 2. C++ Programming examples on “Heaps”

Heap is a partially sorted binary tree. Binary heap is a complete binary tree which satisfies the heap ordering property. The ordering can be done by two types they are min-heap property and max-heap property, The following section deals with the implementation of heaps, binary heap, fibonacci heap, skew heap, ternary heap, d-ary heap, pairing heap, treap, min and max heap.

## 3. C++ Programming examples on “Array, Vector, Stack, Queue and Linked List”

Array is used to store a fixed size sequential collection of elements of same data type. Vectors are same as dynamic arrays with the ability to resize itself automatically when an element is inserted or deleted, with their storage being handled automatically by the container. Stack is a standard C++ container adapter, designed to be used in a LIFO context, and is implemented with an interface/wrapper to the type passed to it as a template argument, which defaults to a deque. Queues are data structures which is similar to stack but it has restrictions on where you can add and remove elements. Singly-linked list, every element contains some data and a link to the next element. Doubly-linked list contains some data, a link to the next node and a link to the previous node. The Following section deals with the implementation of arrays like suffix array, parallel array, sorted and sparse array, vectors implementation, linked links like singly and double linked lists, stacks and queues using linked list and priority queues. This section also explains conversions and expressions of stacks.

**Here’s the list of 1000 C++ Algorithms, Problems & Programming Examples.**