Competitive-Programming Repository
This repostitory contains code for following-
Basic Concepts -
Algorithms
Basic Graph Algorithms
Basic Sorting Algorithms
Basic Recursion Algorithms
Basic Dynamic Programming Algorithms
Basic Greedy Algorithms
Basic Mathematics
Basic Data Structures
GeeksForGeeks
Algorithms
HackerRank
Algorithms
HackerRank Sorting
HackerRank Strings
HackerRank Graph Theory
HackerRank Dynamic Programming
HackerEarth
HackerEarth
CodeMonk
HiringChallenges
CodeChef
LeetCode
#
Title
Solution
Time
Space
Notes
1
Bubble Sort
java
W(|N|) O(|N*N|)
O(|1|)
In-Place, Stable
2
Recursive Bubble Sort
java
W(|N|) O(|N*N|)
O(|1|)
In-Place, Stable
3
Counting Sort
java
4
Insertion Sort
java
W(|N|) O(|N*N|)
O(|1|)
In-Place, Stable, Online
5
Recursive Insertion Sort
java
W(|N|) O(|N*N|)
O(|1|)
In-Place, Stable, Online
6
Radix Sort
java
7
Selection Sort
java
8
Merge Sort
java
O(|N*log(N)|)
O(|N|)
Stable
9
Merge Sort Linked List
java
O(|N*log(N)|)
O(|N|)
Stable
10
Iterative Merge Sort
java
O(|N*log(N)|)
O(|N|)
Stable
11
Quick Sort
java
O(|N*log(N)|)
O(|1|)
In-Place, Stable
12
Iterative Quick Sort
java
O(|N*log(N)|)
O(|1|)
In-Place, Stable
Basic Recursion Algorithms
Basic Dynamic Programming Algorithms
#
Title
Solution
Time
Space
Notes
1
Fibonacci Number DP
java
O(|N|)
O(|N|)
2
Fibonacci Number with Recursion
java
O(|2^N|)
O(|N|)
3
Fibonacci Series with Recursion
java
O(|N|)
O(|1|)
4
Fibonacci Series without Recursion
java
O(|N|)
O(|1|)
5
Edit/Levenshtein Distance
java
O(|M*N|)
O(|M*N|)
6
Min Cost Path
java
O(|M*N|)
O(|M*N|)
#
Title
Solution
Time
Space
Notes
1
Sorted Activity Selection Problem
java
O(|N|)
O(|1|)
2
Unsorted Activity Selection Problem
java
O(|N*log(N)|)
O(|1|)
3
Kruskal Minimum Spanning Tree
java
O(|Elog(E)|) or O(|E log(V)|)
O(|V + E|)
#
Title
Solution
Time
Space
Notes
1
Prime Factors
c++
O(|log(N)|)
O(|1|)
2
Sieve of Eratosthenes
c++
O(|N*log(log(N))|)
O(|N|)
#
Title
Solution
Time
Space
Notes
1
Disjoint Set
java
O(|log(N)|)
O(|N|)
Using Path Compression and Union by Rank
Geeks For Geeks Algorithms
HackerRank Dynamic Programming
Basics of Input Output
BitManipulation
HackerEarth Hiring Challenges
#
Problem
Solution
Time
Space
Points
Notes
1
Find The String
java / python
2
Fredo and Two Strings
cpp / java
Follow my progress -
Hacker Rank
Geeks for Geeks
Hacker Earth
Code Chef
Leet Code
Linkedin