Solutions for Daily Coding Problem, written in Go
- Go >= 1.17
Run make test
to test the solutions.
make test # test all
Number | Difficulty | Asked By | Title |
---|---|---|---|
#1 | EASY | Finding 2 numbers that adds up to k | |
#2 | HARD | Uber | Array multiplication |
#3 | MEDIUM | Tree serialization | |
#4 | HARD | Stripe | Finding lowest positive number |
#5 | MEDIUM | Jane Street | Lisp pair operations |
#6 | HARD | XOR linked list | |
#7 | MEDIUM | Message encoding | |
#8 | EASY | Counting unival tree | |
#9 | HARD | Airbnb | Finding the largest sum of non-adjacent numbers |
#10 | MEDIUM | Apple | Job scheduler |
#11 | MEDIUM | Text autocompletion | |
#12 | HARD | Amazon | Climbing stairs |
#13 | HARD | Amazon | |
#14 | MEDIUM | ||
#15 | MEDIUM | ||
#16 | EASY | ||
#17 | HARD | ||
#18 | HARD | ||
#19 | MEDIUM | ||
#20 | EASY | ||
#21 | EASY | Snapchat | |
#22 | MEDIUM | Microsoft | |
#23 | EASY | ||
#24 | MEDIUM | ||
#25 | HARD | ||
#26 | MEDIUM | ||
#27 | EASY | ||
#28 | MEDIUM | Palantir | |
#29 | EASY | Amazon | |
#30 | MEDIUM | ||
#31 | EASY | ||
#32 | HARD | Jane Street | |
#33 | EASY | Microsoft | |
#34 | MEDIUM | Quora | |
#35 | HARD | Segregating R, G, and Bs in linear time | |
#36 | MEDIUM | Dropbox | Finding the second largest node in BST |
#37 | EASY | Generating the power set of a set | |
#38 | HARD | Microsoft | Arranging N queens without threatening one another |
#39 | MEDIUM | Dropbox | Conway's Game of Life |
#40 | HARD | Finding the non-duplicated number | |
#41 | MEDIUM | Finding full itinerary from a list of flights | |
#42 | HARD | Finding a subset of S that adds up to k | |
#43 | EASY | Amazon | Implementing Stack |
#44 | MEDIUM | Counting inversions in a list of numbers | |
#45 | EASY | Two Sigma | Writing rand function |
#46 | HARD | Amazon | Finding the longest palindromic substring |
#47 | EASY | Calculating maximum profit with chronological stock prices | |
#48 | MEDIUM | Building a tree with given pre-order and in-order traversals | |
#49 | MEDIUM | Amazon | Finding the maximum sum of contiguous subarray |
#50 | EASY | Microsoft | Arithmetic binary tree |
#51 | MEDIUM | Card shuffle | |
#52 | HARD | LRU cache | |
#53 | MEDIUM | Apple | Implementing a queue with 2 stacks |
#54 | HARD | Dropbox | Implementing a Sudoku solver |
#55 | EASY | Microsoft | URL shortener |
#56 | MEDIUM | Map coloring | |
#57 | MEDIUM | Amazon | Splitting string into lines of limited length |
#58 | MEDIUM | Amazon | Search in rotated sorted array |
#59 | HARD | Low bandwidth file synchronization | |
#60 | MEDIUM | Partitioning set by subtotals | |
#61 | MEDIUM | Faster pow operation | |
#62 | MEDIUM | Couting methods to move down | |
#63 | EASY | Microsoft | Finding word left-to-right or up-to-down |
#64 | HARD | Knight's tour on Chessboard | |
#65 | EASY | Amazon | Clockwise matrix traverse |
#66 | MEDIUM | Square | Fair coin toss with a biased coin |
#67 | HARD | LFU cache |