Hacker Newsnew | past | comments | ask | show | jobs | submit | Sherxon's commentslogin

cool (y) I wonder how much time did u spend everyday


Also the thinking process. I looked at the repo it seems straight on solutions.. do not spoil yourself.


Yes, many problems are the same as leetcode problems. The purpose of this repo is just learning.


You are right, thinking logically is always better option than memorizing solutions. To have a good thinking ability, one needs practice. Solving many problems leads you to think different approaches, compute running time and space complexity of your solution before writing code to any problem. I think, this is one of the best ways to improve "thinking".


Right, Deque is also another option, which has the same amortized time complexity and but extra O(n) space is required for Queue. In the given solution, O(n) time complexity and O(1) space is used


Thank you for your comment, I added all problem statements. Find Duplicates are correct and tested against 100 test cases. Problem statement is not what u thought I think. Given an array of integers, 1 ≤ a[i] ≤ n (n = size of array), some elements appear twice and others appear once. Find all the elements that appear twice in this array.


Most of these don't include any commentary about the intuition behind the solutions which is just as important as code. A few do but most of these don't.


The link to hard interview questions is broken, the first letter of the file name is actually capital


i fixed the link, thanks (y)


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: