GithubHelp home page GithubHelp logo

coding_techniques's Introduction

Coding Interview Prep Problems

Collection of tips and tricks for coding interview and competitive coding problems .

DAY 1: 1/8/2019

  1. https://leetcode.com/problems/minimum-window-substring/discuss/26808/here-is-a-10-line-template-that-can-solve-most-substring-problems
  2. https://leetcode.com/problems/two-sum/
  3. https://leetcode.com/problems/best-time-to-buy-and-sell-stock/

Learn:

1.Basics of STL = https://www.youtube.com/playlist?list=PL_dsdStdDXbq8BTjGdUEWgWYFWYP6pwYb

Day 2: 2/8/2019

  1. https://leetcode.com/problems/contains-duplicate/ (sort and check adjacent elements (gives runtime error))
  2. Product of Array Except Self: https://leetcode.com/problems/product-of-array-except-self/

Learn:

  1. How to Pass by reference(C++) : https://www.ibm.com/support/knowledgecenter/en/SSLTBW_2.3.0/com.ibm.zos.v2r3.cbclx01/cplr233.htm
  2. C++ STL: Set : https://www.geeksforgeeks.org/set-in-cpp-stl/

Day 3: 4/8/2019

6.https://leetcode.com/problems/maximum-subarray/

Learn:

  1. https://www.geeksforgeeks.org/int_max-int_min-cc-applications/

Day 4: 5/8/2019

  1. https://leetcode.com/problems/find-minimum-in-rotated-sorted-array/solution/

Learn:

  1. https://www.geeksforgeeks.org/c-data-types/
  2. https://www.geeksforgeeks.org/binary-search/

Day 5: 28/8/2019

  1. https://leetcode.com/problems/remove-duplicates-from-sorted-array/
  2. https://leetcode.com/problems/remove-duplicates-from-sorted-list/submissions/
  3. https://leetcode.com/problems/linked-list-cycle/

Day 6: 29/8/2019

  1. https://leetcode.com/problems/intersection-of-two-linked-lists/
  2. https://leetcode.com/problems/middle-of-the-linked-list/
  3. https://leetcode.com/problems/reverse-linked-list/submissions/

Day 7: 30/8/2019

  1. https://leetcode.com/problems/find-the-town-judge/ (Graph)

Day 8: 1/9/2019

  1. https://leetcode.com/problems/sort-array-by-parity-ii/submissions/

Learn: Java Multithreading.

Day 9: 2/9/2019

  1. https://leetcode.com/problems/maximum-depth-of-n-ary-tree/

Day 10: 12/9/2019

  1. https://leetcode.com/problems/to-lower-case/submissions/

Day 11: 1/10/2019

  1. https://www.hackerrank.com/challenges/mini-max-sum/problem

Day 12: 9/10/2019

Learnt and Implemented Segment Tree: https://cp-algorithms.com/data_structures/segment_tree.html

Day 13: 16/10/2019

  1. https://leetcode.com/problems/third-maximum-number/submissions/

Day 14: 17/10/2019

  1. https://leetcode.com/problems/relative-sort-array/submissions/

Day 15: 18/10/2019

  1. https://leetcode.com/problems/sum-of-even-numbers-after-queries/submissions/

Day 16: 19/10/2019

  1. https://leetcode.com/problems/maximum-product-of-three-numbers/submissions/

Day 17: 20/10/2019

  1. https://leetcode.com/problems/min-cost-climbing-stairs/submissions/
  2. https://leetcode.com/problems/defanging-an-ip-address/submissions/

Day 18: 24/10/2019

  1. https://leetcode.com/problems/sort-array-by-parity/
  2. https://leetcode.com/problems/find-all-numbers-disappeared-in-an-array/
  3. https://leetcode.com/problems/squares-of-a-sorted-array/
  4. https://leetcode.com/problems/fibonacci-number/

Day 19: 25/10/2019

Learnt and implemented: BFS and DFS.

Day 20: 29/10/2019

  1. https://leetcode.com/problems/x-of-a-kind-in-a-deck-of-cards/

Day 21: 30/10/2019

  1. https://leetcode.com/problems/duplicate-zeros/
  2. https://leetcode.com/problems/unique-morse-code-words/

Day 22: 2/10/2019

https://leetcode.com/problems/divisor-game/

Day 23: 3/10/2019

  1. https://leetcode.com/problems/is-subsequence/submissions/
  2. https://leetcode.com/problems/climbing-stairs/
  3. https://leetcode.com/problems/range-sum-query-immutable/

Day 24: 21/11/2019

  1. https://leetcode.com/problems/flipping-an-image/

Day 25: 30/11/2019

  1. https://leetcode.com/problems/maximum-average-subarray-i/

Day 26: 20/12/2019

  1. https://leetcode.com/problems/distribute-candies-to-people/
  2. https://leetcode.com/problems/complement-of-base-10-integer/
  3. https://leetcode.com/problems/largest-perimeter-triangle/

Day 27: 25/2/2020

  1. https://leetcode.com/problems/max-consecutive-ones/

Day 28: 28/2/2020

  1. https://leetcode.com/problems/valid-mountain-array/
  2. https://leetcode.com/problems/shortest-unsorted-continuous-subarray/
  3. https://leetcode.com/problems/find-first-and-last-position-of-element-in-sorted-array/
  4. https://leetcode.com/problems/number-of-steps-to-reduce-a-number-to-zero/

Note:

When we copy contents of one variable to other simply by assigning in python, we create an Alias, not a separate copy. https://www.geeksforgeeks.org/copy-python-deep-copy-shallow-copy/

Day 29: 29/02/2020

  1. https://leetcode.com/problems/container-with-most-water/

Day 30: 1/03/2020

  1. https://leetcode.com/problems/pascals-triangle/

Day 31: 9/03/2020

  1. https://leetcode.com/problems/verifying-an-alien-dictionary/
  2. https://www.hackerrank.com/challenges/find-digits/problem
  3. https://www.hackerrank.com/challenges/cut-the-sticks/problem

Day 32: 10/03/2020

  1. https://leetcode.com/problems/assign-cookies/
  2. https://www.hackerrank.com/challenges/luck-balance/problem
  3. https://www.hackerrank.com/challenges/permutation-equation/problem

Note:

  1. In Python 3, False == 0 evaluates to True.
  2. Sorting a List of List by specific index. :- https://www.geeksforgeeks.org/python-sort-list-of-list-by-specified-index/
  3. sizeof() equivalent of C in Python:- :- step 1: import sys step 2: sys.getsizeof(object)

Day 33: 11/03/2020

  1. https://leetcode.com/problems/validate-binary-search-tree/
  2. https://leetcode.com/problems/add-strings/

Day 34: 12/03/2020

  1. https://leetcode.com/problems/sort-the-matrix-diagonally/

Day 35: 19/03/2020

  1. https://leetcode.com/problems/count-square-submatrices-with-all-ones/
  2. https://www.hackerrank.com/challenges/finding-the-percentage/problem?isFullScreen=false
  3. https://www.hackerrank.com/challenges/find-second-maximum-number-in-a-list/problem

Day 36: 21/03/2020

  1. https://www.hackerrank.com/challenges/alphabet-rangoli/problem
  2. https://www.hackerrank.com/challenges/list-comprehensions/problem

Day 37: 22/03/2020

  1. https://www.hackerrank.com/challenges/find-a-string/problem https://www.geeksforgeeks.org/kmp-algorithm-for-pattern-searching/

Day 38: 23/03/2020

  1. https://www.hackerrank.com/challenges/capitalize/problem

Day 39: 31/03/2020

  1. https://leetcode.com/problems/kth-smallest-element-in-a-bst/

Day 40: 1/04/2020

  1. https://leetcode.com/problems/search-in-a-binary-search-tree/

Participating in CodeChef 2020 April B

Day 41: 17/5/2020

  1. https://leetcode.com/problems/queens-that-can-attack-the-king/

Day 42: 24/5/2020

  1. https://leetcode.com/problems/hand-of-straights/ Solution: https://leetcode.com/problems/hand-of-straights/discuss/354105/Fully-Explained-Python-Solution

  2. https://leetcode.com/problems/average-of-levels-in-binary-tree/

Day 43: 25/5/2020

  1. https://leetcode.com/problems/find-mode-in-binary-search-tree/

Day 44: 26/5/2020

  1. https://leetcode.com/problems/lowest-common-ancestor-of-a-binary-search-tree/
  2. https://leetcode.com/problems/binary-tree-paths/

Day 45: 27/5/2020

  1. https://leetcode.com/problems/longest-continuous-increasing-subsequence/

Day 46: 29/5/2020

  1. https://leetcode.com/problems/min-stack/
  2. https://leetcode.com/problems/monotonic-array/
  3. https://leetcode.com/problems/maximum-depth-of-n-ary-tree/

Day 47: 31/5/2020

  1. https://leetcode.com/problems/reshape-the-matrix/
  2. https://leetcode.com/problems/maximum-number-of-balloons/
  3. https://leetcode.com/problems/minimum-absolute-difference/

Day 48: 1/6/2020

  1. https://leetcode.com/problems/unique-number-of-occurrences/
  2. https://leetcode.com/problems/degree-of-an-array/
  3. https://leetcode.com/problems/flood-fill/
  4. https://leetcode.com/problems/valid-anagram/
  5. https://leetcode.com/problems/third-maximum-number/

Day 49: 2/6/2020

  1. https://leetcode.com/problems/plus-one/
  2. https://leetcode.com/problems/add-binary/ : How to handle large number divisions
  3. https://leetcode.com/problems/valid-parentheses/
  4. https://leetcode.com/problems/word-pattern/

Day 50: 3/6/2020

  1. https://leetcode.com/problems/longest-common-prefix/
  2. https://leetcode.com/problems/remove-linked-list-elements/
  1. https://leetcode.com/problems/rectangle-overlap/

Day 51: 4/6/2020

  1. https://leetcode.com/problems/longest-palindrome/
  2. https://www.hackerrank.com/challenges/picking-numbers/problem
  3. https://leetcode.com/problems/number-of-lines-to-write-string/
  4. https://leetcode.com/problems/find-pivot-index/
  5. https://leetcode.com/problems/smallest-range-i/

Day 52: 8/6/2020

  1. https://leetcode.com/problems/subtree-of-another-tree/
  2. https://leetcode.com/problems/asteroid-collision/

Day 53: 10/10/2020

  1. https://www.hackerrank.com/challenges/jumping-on-the-clouds-revisited/problem

Day 54: 11/10/2020

  1. https://www.hackerrank.com/challenges/strange-advertising/problem
  2. https://www.hackerrank.com/challenges/append-and-delete/problem
  3. https://www.hackerrank.com/challenges/library-fine/problem
  4. https://www.hackerrank.com/challenges/repeated-string/problem
  5. https://www.hackerrank.com/challenges/equality-in-a-array/problem
  6. https://www.hackerrank.com/challenges/string-validators/problem
  7. https://www.hackerrank.com/challenges/text-alignment/problem
  8. https://www.hackerrank.com/challenges/python-string-formatting/problem
  9. https://www.hackerrank.com/challenges/merge-the-tools/problem

Day 55: 26/10/2020

  1. https://leetcode.com/problems/add-two-numbers/
  2. https://leetcode.com/problems/longest-substring-without-repeating-characters/

Day 56: 21/03/2023

  1. https://leetcode.com/problems/find-the-index-of-the-first-occurrence-in-a-string/submissions/919373474/
  2. https://leetcode.com/problems/length-of-last-word/

Day 57: 28/03/2023

  1. https://leetcode.com/problems/valid-palindrome/description/
  2. https://leetcode.com/problems/single-number/description/

Day 58: 31/03/2023

  1. https://leetcode.com/problems/majority-element/description/
  2. https://leetcode.com/problems/excel-sheet-column-number/description/
  3. https://leetcode.com/problems/number-of-1-bits/description/

Day 59: 03/04/2023

  1. https://leetcode.com/problems/happy-number/description/
  2. https://leetcode.com/problems/isomorphic-strings/description/

Day 60: 09/04/2023

  1. https://leetcode.com/problems/contains-duplicate-ii/description/

Day 61: 11/04/2023

  1. https://leetcode.com/problems/first-unique-character-in-a-string/description/
  2. https://leetcode.com/problems/power-of-two/description/

Day 62: 13/04/2023

  1. https://leetcode.com/problems/arranging-coins/description/
  2. https://leetcode.com/problems/find-n-unique-integers-sum-up-to-zero/description/

Day 63: 18/04/2023

  1. https://leetcode.com/problems/longest-palindromic-substring/description/
  2. https://leetcode.com/problems/palindrome-number/description/

Day 64: 12/06/2023

  1. https://leetcode.com/problems/convert-sorted-array-to-binary-search-tree/description/

Day 65: 03/10/2023

  1. https://codeforces.com/problemset/problem/1549/B

Day 66: 04/10/2023

  1. https://www.spoj.com/problems/TEST/
  2. https://codeforces.com/problemset/problem/4/A
  3. https://codeforces.com/problemset/problem/71/A
  4. https://codeforces.com/problemset/problem/231/A
  5. https://codeforces.com/problemset/problem/96/A

Day 67: 06/10/2023

  1. https://codeforces.com/problemset/problem/405/A

coding_techniques's People

Contributors

debayon avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.