Apurv7777 / Data-Structures-and-Algorithms

Crisp and self explanatory codes for various DSA Problems from online platforms like Geeksforgeeks and leetcode

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

✨DSA using C++✨

Data Structures in Big O Notation

Data Structure Add/Insert Remove/Delete Access/Get Search/Contains Space Complexity
Array O(n) O(n) O(1) O(n) O(n)
Set O(logn) O(logn) - O(logn) O(n)
Unordered Set O(1)Average O(n)Worst O(1)Average O(n)Worst - O(1)Average O(n)Worst O(n)
Map O(logn) O(logn) - O(logn) O(n)
Unordered Map O(1)Average O(n)Worst O(1)Average O(n)Worst - O(1)Average O(n)Worst O(n)
Singly LinkedList O(1) O(1) O(n) O(n) O(n)
Doubly LinkedList O(1) O(1) O(n) O(n) O(n)
Circular Singly LinkedList O(1) O(1) O(n) O(n) O(n)
Circular Doubly LinkedList O(1) O(1) O(n) O(n) O(n)
Stack O(1) O(1) O(n) O(n) O(n)
Queue O(1) O(1) O(n) O(n) O(n)
HashMap O(1) O(1) O(1) O(1) O(n)
Binary Search Tree O(log n) O(log n) O(log n) O(log n) O(n)
Binary Min Heap O(log n) O(log n) O(1) O(n) O(n)
Binary Max Heap O(log n) O(log n) O(1) O(n) O(n)

Topic wise problems' list

⭕ Sliding window leetcode:

Problem Topic Question link Solution my article/article from discussion tab
longest substring without repeating characters sliding window link link
minimum window substring sliding window link link link
maximum consecutive ones 3 sliding window link link
longest repeating character replacement sliding window link link
Subarrays with K Different Integers sliding window link link link
longest substring with at most k distinct characters sliding window leetcode premium link link
longest subarray with difference less than limit sliding window link link link

Day wise progress

🔺Day 89 to Day 103 : Google step interview preparation

🔺Day 88 :

Problem Topic Question link Solution
link link

🔺Day 87 :

Problem Topic Question link Solution
maximum product subarray kadane's algo link link
sort colors dnf sort link link
minimum days to make m bouquets binary search link link

🔺Day 86 :

Problem Topic Question link Solution
odd even linked list linked list link link
3 Sum two pointers link link
  • revised other topics

🔺Day 85 :

Problem Topic Question link Solution
single number bit manipulation link link
majority element arrays link link
container with most water two pointers link link
house robber arrays link link

🔺Day 84 :

Problem Topic Question link Solution
longest subarray with difference less than limit sliding window link link
longest substring with at most k distinct characters sliding window leetcode premium link
Subarrays with K Different Integers sliding window link link
  • and revised some topics

🔺Day 83 :

Problem Topic Question link Solution
longest substring without repeating characters sliding window link link
minimum window substring sliding window link link
maximum consecutive ones 3 sliding window link link
longest repeating character replacement sliding window link link

🔺Day 82 :

🔺Day 81 :

🔺Day 80 :

🔺Day 79 :

  • learnt about heaps and priority queues

🔺Day 78 :

1. solved following questions on graphs:

🔺Day 77 :

1. solved following questions on graphs:

🔺Day 76 :

1. solved following questions on graphs:

🔺Day 75 :

1. solved 2 questions from codeforces:

🔺Day 74 :

1. continued learning graphs. Learnt about traversal techniques (bfs, dfs), connected components etc.

🔺Day 73 :

1. solved 2 questions from codeforces:

2. revised recursion

🔺Day 72 :

1. started learning graphs

2. solved a question from codeforces:

🔺Day 71 :

1. started learn heaps

2. Solved two questions from codeforces:

🔺Day 70 :

1. Solved problems on BSTs:

2. solved a question from codeforces:

🔺Day 69 :

1. Solved problems on BSTs:

🔺Day 68 :

1. Solved problems on BSTs and some on binary trees:

2. Appeared for codeforces round #744 div 3 and solved 2 questions:

🔺Day 67 :

1. Solved problems on BSTs:

2. Appeared for CodeChef Starters 13 div 2 and solved 3 problems

🔺Day 66 :

1. Learnt about how binary search tree works. Learnt about AVL trees and Red Black trees mechanism

2. Solved Some basic problems:

3. Appeared for CodeChef September Lunchtime and solved 2 questions in Div 2:

🔺Day 65 :

1. Started with Binary Search Trees

2. Solved some basic problems:

🔺Day 64 :

1. Revised Binary trees since I feel that I am still a little bit weak at this.

2. Solved 2 Codeforces problems:

🔺Day 63 :

1. Solved following problems:

🔺Day 62 :

1. Solved following problems:

🔺Day 61 :

1. Appeared for codechef starters 11 andd solved following questions

🔺Day 60 :

  • Revised Binary Trees

🔺Day 59 :

🔺Day 58 :

1. Solved following problems:

🔺Day 57 :

1. Solved following problems:

🔺Day 56 :

1. Solved following problems:

🔺Day 55 :

1. Revised all Binary trees concepts (because of long break due to unavoidable conditions).

2. Covered few basic problems:

3. Updated readme and added few notes.

🔺Day 54 :

1. Completed my UI/UX Challenge 1 from developer days and did ux research for an application.

🔺Day 53 :

1. Completed basics of binary trees:

2. Solved following problems:

🔺Day 52 :

1. Started learning tree concepts

2. Solved some basic problems:

🔺Day 51 :

1. Appeared for august division 3 starters and solved 2 questions:

2. Appeared for LGM - HEIST 2021 coding competition and solved 3 questions:

🔺Day 50 :

1. revised previously learnt concepts

2. Solved one from codechef long challenge

🔺Day 49 :

1. Solved following problems:

🔺Day 48 :

1. Learnt advanced queue and deque concepts

🔺Day 47 :

1. Learnt the concepts of queues and dequeues:

2. Solved 3 problems from CodeChef August Long Challenge: (will upload after the contest)

3. Solved following problems:

🔺Day 46 :

1. Learnt basic concepts of queues :

2. Appeared for icpc and solved one question

🔺Day 45 :

1. Started learning concepts of queues

2. Solved following problems on stacks:

🔺Day 44 :

1. Covered advanced concepts of stacks

2. Solved following problems :

🔺Day 43 :

1. Learnt basics of stacks

2. Solved following problems :

🔺Day 42 :

1. Solved following questions on bit manipulation

2. Appeared for codechef july lunchtime and solved 3 problems:

🔺Day 41 :

1. Solved following questions on bit manipulation

2. Appeared for codforeces educational round 112 and solved one question

🔺Day 40 :

1. Revised Linked lists

2. Solved following problems on linked lists :

3. Appeared for codeforces round 735 and solved one question:

🔺Day 39 :

1. Solved following problems on linked lists :

🔺Day 38 :

1. Solved following problems on linked list :

🔺Day 37 :

1. Appeared for Codechef Div 3 starters and solved 4 problema:

2. Covered advanced linked list concepts

3. Solved following problems on linked list:

🔺Day 36 :

3. Solved some basic problems on doubly linked list and circular linked list

4. Appeared for Codeforces Round #734 Div 2 and solved 2 questions and upsolved one more

🔺Day 35 :

1. Learnt about Doubly linked list

2. Solved following problems:

🔺Day 34 :

🔺Day 33 :

1. Solved following problems:

🔺Day 32 :

1. Revised previously covered topics

2. Appeared for codeforces Educational Round 111 and solved 1 problem :

🔺Day 31 :

1. Solved following problems:

2. Continued Pepcoding Recursion playlist

🔺Day 30 :

1. Solved following problems:

2. Continued pepcoding recursion playlist

🔺Day 29 :

1. Continued Advanced Recursion and Backtracking tutorials

2. Appeared for Google kickstart Round D and solved 1 question

3. Appeared for codeforces round #732

4. Solved permutations of a given string

🔺Day 28 :

1. Continued Advanced Recursion and Backtracking tutorials

2. Appeared for Codeforces round #731 and solved two

🔺Day 27 :

1. Continued Advanced Recursion and Backtracking tutorials

2. Solved following problems:

🔺Day 26 :

1. Continued Recursion and Backtracking tutorials

🔺Day 25 :

1. Appeared for Codeforces round #730 and solved two questions

2. Solved following problems:

3. Added README.md in recursion and backtracking folder

🔺Day 24 :

1. Solved following problems:

  1. Added following under math tricks folder:

🔺Day 23 :

1. Solved Basic matrix questions

🔺Day 22 :

1. Solved following problems:

2. continued Recursion learning series

🔺Day 21 :

1. Solved following problems:

🔺Day 20 :

1. Solved following problems:

2. Started with lil bit of Recursion

🔺Day 19 :

1. Solved following problems:

🔺Day 18 :

1. Appeared For CodeChef Starters and solved 3 problems and upsolved one more

2. Solved following problems on hashing :

🔺Day 17 :

1. Appeared For CodeChef Lunchtime and solved 4 problems and upsolved one more

2. Focused on Hashing concepts

3. Appended Math Tricks folder by adding "Recurring Decimal"

🔺Day 16 :

1. Appeared for Codeforces Round 728 and solved one question and upsolved 1 more

2. Learnt some more hashing concepts

3. Learnt some precomputation techniques in 2D arrays

🔺Day 15 :

1. Completed basics of Hashing and created inside Hashing folder to list down the conclusion

2. Learnt About Sets and Maps

3. Solved following problems

🔺Day 14 :

1. Learnt basics of oops

2. Learnt Maps and unordered maps

3. Solved following problems

🔺Day 13 :

1. Solved following Problems:

🔺Day 12 :

1. Solved following Problems:

🔺Day 11 :

1. Solved following Problem:

2. Revised previously learnt concepts

🔺Day 10 :

1. Solved following Problems:

🔺Day 09 :

1. Solved following Problem:

🔺Day 08 :

1. Solved following Problems:

2. Tried but not accepted:🙁

  • Shortest route from june long challenge

3. advanced searching techniques

🔺Day 07 :

1. Created Math tricks folder and added some basic concepts like:

2. Did some basic Searching Problems

3. Tried but not accepted: 🙁

  • Bitwise Tuple from june long challenge

4. Continued learning advanced sorting and searching techniques

🔺Day 06 :

Contributed to LGM SOC'21 and learnt the basic etiquette of contributing to open source

🔺Day 05 :

1. Solved following Problems:

2. Continued learning advanced sorting and searching techniques

🔺Day 04 :

1. Solved following Problems:

2. Continued learning advanced sorting and searching techniques

🔺Day 03 :

1. Solved following Problems:

2. Learnt Basic Searching and Sorting concepts

🔺Day 02 :

1. Solved 2 questions from codechef june long challenge (Couldn't post it here right now since contest is still on😅)

2. Appeared for Codeforces Educational Round 110.

3. Solved following Problems:

4. Tried but not accepted:

  • Count Inversion
  • Codeforces question B from today's contest

5. Learnt Basic Searching and Sorting concepts

🔺Day 01 :

1. Revised all the sorting Algorithms and created Analysis.md under Sorting folder and added the crux of it there.

2. Added codes for following sorting algorithms:

🔺Day 00 :

1. Added previously solved good questions to the repo which I did before taking up the challenge

2. Planning for 100 days of code

About

Crisp and self explanatory codes for various DSA Problems from online platforms like Geeksforgeeks and leetcode


Languages

Language:C++ 99.6%Language:Java 0.4%