Stories, Tutorials
& Life Tips
Deep dives on coding, health, recipes, travel and everything in between.

Given a linked list, remove the nth node from the end of the list and return its head. For example, Given linked list: 1->2->3->4->5, an…
📍 Explore Reading Paths
Follow curated journeys from beginner to expert
How to Design a web crawler
Step 1: Outline use cases and constraintsGather requirements and scope the problem. Ask questions to clarify use cases and constraints. Discuss assumptions. Without an interviewer to address clarifyin…
How to Design the Twitter timeline and search
Design the Facebook feed and Design Facebook search are similar questions. Step 1: Outline use cases and constraintsGath…
How to Design Pastebin.com (or Bit.ly)
Design Bit.ly - is a similar question, except pastebin requires storing the paste contents instead of the original unsho…
How to approach a system design interview question?
The system design interview is an open-ended conversation. You are expected to lead it. You can use the following steps …
Teemo Attacking - Array - Medium - LeetCode
In LOL world, there is a hero called Teemo and his attacking can make his enemy Ashe be in poisoned condition. Now, give…
Circular Array Loop - Array - Medium - LeetCode
You are given a circular array nums of positive and negative integers. If a number k at an index is positive, then move …
Find All Duplicates in an Array - Array - Medium - LeetCode
Given an array of integers, 1 ≤ a[i] ≤ n (n = size of array), some elements appear twice and others appear once. F…
Insert Delete GetRandom O(1) - Array - Medium - LeetCode
Implement the RandomizedSet class: bool insert(int val) Inserts an item val into the set if not present. Returns true if…
Game of Life - Array - Medium - LeetCode
According to the Wikipedia's article: "The Game of Life, also known simply as Life, is a cellular automaton devised by t…
Find the Duplicate Number - Array - Medium - LeetCode
Given an array of integers nums containing n + 1 integers where each integer is in the range [1, n] inclusive. There is …
Product of Array Except Self - Array - Medium - LeetCode
Given an array nums of n integers where n > 1, return an array output such that output[i] is equal to the produ…
Majority Element II - Array - Medium - LeetCode
Given an integer array of size n, find all elements that appear more than ⌊ n/3 ⌋ times. Follow-up: Could …
Combination Sum III - Array - Medium - LeetCode
Find all valid combinations of k numbers that sum up to n such that the following conditions are true: Only numbers 1 th…
Minimum Size Subarray Sum - Array - Medium - LeetCode
Given an array of n positive integers and a positive integer s, find the minimal length of a contiguous subarray of whic…
Rotate Array - Array - Medium - LeetCode
Given an array, rotate the array to the right by k steps, where k is non-negative. Follow up: Try to come up as many sol…