Data structures and algorithms in c++
Sometimes unnecessary header files are included, it is because I forgot to check header file when solved next problems. You can simply remove if it is not required :).
Please follow to learn topic in below order to get most of it.
If you have basic knowledge of any data structures. You can directly go to section then.
For Building Fundamentals
Time and Space Complexity (Basics must know before start)
Bit Manipulation (Can be skipped too)
Character Array (Strings)
Merge Sort and Quick Sort
Topological Sort (Algorithm)
Basics Revise (Reference)
#
Title
Solution
1
Delete First Element Of Array
C++
2
Enumeration Explanation
C++
3
Graph Basics
C++
4
Hash Table Basics
C++
5
Taking Input In Line With or Without Space
C++
6
Taking Input In Line With or Without Space (Second Way)
C++
7
Pointers Using Integers
C++
8
Linked list implementation
C++
9
Difference Between Pre(++i) and Post Increment(i++)
C++
10
Queue Basics
C++
11
Stack Basics
C++
12
String Literal and C String
C++
13
Structure Concept
C++
14
Tree Basics
C++
15
Union Basics
C++
16
Vector Basics
C++
#
Title
Solution
1
Bit Manipulation Introduction
C++
2
Check If Given Number Is Odd or Even Using Bitwise Operators
C++
#
Title
Solution
1
Big O Cheatsheet
C++
2
Passing Array As Input
C++
3
Calculate Time Taken In Prohram Using Chrono
C++
4
Calculate Time Taken In Prohram Using ctime
C++
#
Title
Solution
1
Hashmap Intro
C++
2
Remove Duplicates In A Given Array
C++
3
Iterators
C++
4
Hashmap Insert Implementation
C++
5
Hashmap Delete & Search Implementation
C++
6
Rehashing
C++
#
Title
Solution
1
Priority Queue Basic Implementation
C++
2
Remove Minimum Value In Min Heap
C++
3
Heap Sort (In-Place)
C++
4
Priority Queue (In-Built STL)
C++
5
Minimum Priority Queue (In-Built)
C++
6
K Smallest Element
C++
7
K Sorted Array
C++
8
K Smallest Using Minimum Priority Queue
C++
#
Title
Solution
1
Fibonacci Number
C++
2
Sum Upto A Number
C++
3
Print Upto A Number
C++
4
Calculate Power of N
C++
5
No of Digits In A Number
C++
6
Sum of Digits of A Number
C++
7
Multiply Two Numbers Without Using * Operator
C++
8
Count No of Times Zero Appear In A Number
C++
9
Calculate Geometric Sum Upto A Given Number
C++
10
Reverse A Given Number
C++
Advanced
Advanced
11
Check If Array Is Sorted or Not
C++
12
Calculate Sum of A Given Array
C++
13
Check If Given Element Is Present In An Array
C++
14
Find First Index of The Given Element In An Array
C++
15
Find Last Index of The Given Element In An Array
C++
16
Print All Position of A Given Element In An Array
C++
17
Count The Occurence of A Given Element In An Array
C++
18
Store All Position of A Given Element In An Array
C++
19
Check If A Given Element Is Palindrome
C++
20
Given A String(Character Array) Print String And Its Reverse
C++
21
Length of The Character Array(String)
C++
22
Replace Every Character In A String With A Given Character
C++
23
Replace Every Occurrence of A Character To A Given Character In A String
C++
24
Remove Given Array From A Character Array (String)
C++
25
Given A Character Array Remove Consecutive Duplicates of Any Character
C++
26
Print All Subsequence of A Given String
C++
27
Store All The Subsequence of A String
C++
28
Convert A Given String Into An Integer Number
C++
29
Print All Permutation of A String
C++
30
Staircase
C++
31
Tower of Hanoi
C++
32
Print Steps To Solve Tower of Hanoi
C++
#
Title
Solution
1
Stack Implementation Using Array
C++
2
Dynamic Stack Implementation Using Array
C++
3
Stack Implementation Using Vector
C++
4
Stack Implementation Using Array (Templates)
C++
5
Stack Implementation Using Linked List (Generic)
C++
6
Stack (In-Built STL)
C++
7
Valid Parentheses
C++
8
Evaluate Reverse Polish Notation
C++
9
Remove All Adjacent Duplicates In String
C++
##
Stack Implementation
C++
#
Title
Solution
1
Queue Implementation Using Array
C++
2
Dynamic Queue Using Array
C++
3
Queue Implementation Using Linked List
C++
4
Queue (In-Built STL)
C++
5
Reverse A Queue
C++
#
Queue Implementation
C++
#
Design Circular Queue
C++
#
Circular Queue Implementation
C++
#
Title
Solution
1
String Basic Operations
C++
#
Title
Solution
1
Why Templates (Different Scenario)
C++
2
Using Templates In Class
C++
3
Using Templates With Multiple Data Types
C++
4
Using Templates In Pair Triplets
C++
#
Title
Solution
1
Tree Introduction and Implementation
C++
2
Print A Tree
C++
3
Taking Input Recursively In Tree
C++
4
Taking Input Level Wise
C++
5
Printing Tree Level Wise
C++
6
Count Total Nodes In A Tree (Recursively)
C++
7
Count No of Nodes Iteratively Using Queue
C++
8
Calculate Height of Tree
C++
9
print Nodes At K Level/Depth
C++
10
Count Leaf Nodes In A Tree
C++
11
Pre Order Traversal of A Tree
C++
12
Post Order Traversal of A Tree
C++
13
Delete A Tree
C++
14
Deleting a Tree Using Destructor
C++
#
Title
Solution
1
Trie Introduction & Implementation
C++