Site Map

Difficulty Levels

Beginner Intermediate Expert


1 Graph 2 Dynamic programming
3 Strings 4 Binary Tree
5 Arrays 6 Linked List
7 Backtracking 8 Divide and Conquer
9 Numbers 10 Priority Queue
11 Recursion 12 Search
13 Pair 14 Deque
15 Sorting Techniques 16 Bit Manipulation Problems

Top Companies Interview Questions

1 Google 2 Microsoft
3 Amazon 4 Facebook
5 Adobe 6 Apache
7 Bloomberg 8 Epic Systems
9 Flipkart 10 Goldman Sachs
11 Groupon 12 LinkedIn
13 NetApp 14 NVIDIA
15 Oracle 16 Qualcomm
17 Twitter 18 Yahoo

All Problems

Find Nth-term of an arithmetic progression2021-04-18 22:31:27
Minimum time difference2021-04-11 23:01:01
Find departure and destination cities from the itinerary2021-01-28 22:26:08
Rank Array Elements2021-01-24 22:23:41
Three Consecutive Odd Numbers2021-01-21 23:19:59
Non-decreasing Array with one allowed change2021-01-20 22:39:26
Duplicate zero’s without expanding the array.2021-01-14 22:52:31
Maximum Depth of Valid Nested Parentheses2021-01-10 21:13:07
Decimal to Binary2021-01-08 00:50:53
Maximum Consecutive Ones2021-01-07 01:40:52
Duplicate even elements in an array2021-01-01 21:18:33
Minimum Increments to make all array elements unique2020-12-23 23:24:49
Add digits until number becomes a single digit2020-12-20 13:13:35
Maximum Surpasser in the given array2020-12-18 00:53:54
Find the number of pairs with odd XOR2020-12-17 00:34:36
Maximum CPU Load Problem2020-12-14 00:51:05
Add digits until the number becomes a single digit2020-12-12 22:08:04
Student Attendance Reward2020-12-12 00:16:39
Count Maximum overlaps in a given list of time intervals2020-12-11 00:58:18
Remove Duplicates from Sorted Array2020-12-09 23:27:09
Get a random character from the given string – Java Program2020-12-06 22:31:39
Replace Elements with Greatest Element on Right2020-12-05 21:56:11
Count number of pairs which has sum equal to K2020-12-04 22:46:48
Count similar words in a given array2020-12-04 00:14:48
Maximum distance from the nearest person.2020-12-03 00:38:26
Sort 0’s, the 1’s and 2’s in the given array – Dutch National Flag algorithm | Set – 22020-11-29 16:05:30
Sort 0’s, the 1’s, and 2’s in the given array. | Set – 12020-11-29 00:50:00
Override List Collections Sort Method2020-11-28 00:58:49
Overlapping sum of two arrays.2020-11-26 21:32:51
Candidate Voting Problem2020-11-25 22:20:52
Number of Contiguous Parking Areas2020-11-22 21:02:38
Pascal Triangle – Get specific row K2020-11-12 00:56:24
Design data structure for players and ranks2020-11-05 21:03:34
Maximum Bipartite Matching Problem2020-10-31 14:00:11
Override Arrays Sort Method – Java2020-10-30 21:38:40
Pascal Triangle2020-10-29 23:41:59
Minimum Deletions to make the occurrence of each character unique.2020-10-28 22:00:30
Calculate tax on income as per given tax brackets.2020-10-27 21:39:53
Valid Pickup and Delivery options2020-10-15 21:29:48
Print Top 10 videos from List2020-10-08 23:22:08
Compare two version numbers of a software2020-09-20 21:15:12
The largest number can be formed from the given number2020-09-19 00:09:34
Minimum number of adjacent swaps to sort the given array2020-09-16 22:34:03
Minimum number of times String A is repeated to such that B is substring of A2020-09-13 22:50:24
Print all nested directories and files in a given directory – Recursion2020-09-11 21:10:50
Check if the given playlist of programs is valid2020-09-11 00:33:49
Maximum meetings in one room2020-09-10 00:18:10
Find the number of pairs with even XOR2020-09-06 14:15:44
Unresolved references error – Django in PyCharm and IntelliJ2020-09-06 00:10:55
Given an array, Find the number of all pairs with even sum2020-09-01 20:46:25
The number of cycles in a given array of integers.2020-08-24 22:11:42
Check if given sudoku is valid or not2020-08-21 22:22:08
Find Election Winner2020-08-19 23:24:44
Sort the indexes of the array as per the elements of the array2020-08-06 23:00:02
Construct the Largest number from the given digits2020-08-06 00:05:51
Print all subarrays using recursion2020-08-04 19:03:14
Find Lexicographically smallest or largest substring of size k2020-08-02 21:34:26
Largest word in dictionary by removing a few characters from the given string2020-08-01 23:19:34
Calculate (x^y)%z without using pow() function2020-07-01 23:36:34
Check if one string is a subsequence of another string.2020-06-17 23:39:48
Most frequent word2020-06-07 23:51:44
Efficient Robot Problem – Find Minimum Trips2020-06-05 22:40:40
Job Sequencing algorithm – Java2020-06-03 22:35:58
Find subarray with a sum to given number-2 | Handle negative numbers2020-06-01 23:39:40
Sort the two dimensional (2D) array – In-place2020-05-22 21:02:25
Implement/Design the version control map system2020-05-19 23:03:58
Given an array, count the number of pairs with a given sum.2020-05-17 21:10:53
Sort Map as per values – Java Program2020-05-07 22:59:13
Two Sum Problem2020-05-05 23:23:57
Find if any two intervals overlap in given intervals2020-04-16 23:43:47
Given an array, find the number of all pairs with odd sum.2020-04-14 23:37:28
Given an array, find all unique subsets with a given sum with allowed repeated digits.2020-04-13 00:06:20
Print all steps to convert one string to another string2020-04-09 00:35:33
Lexicographically next permutation With One swap2020-04-06 22:57:48
Find all subsets of size K from a given number N (1 to N)2020-04-04 22:54:52
Sum of distinct elements among two given sets2020-04-02 22:39:14
Find all possible combinations with sum K from a given number N(1 to N) with the repetition of numbers is allowed2020-03-22 22:55:27
Stable Marriage Problem – Gale–Shapley Algorithm – Java2020-03-14 23:08:29
Insert a node in the given sorted linked list.2020-02-17 22:30:38
Construct the largest number from the given array.2020-02-14 00:01:41
Given an array, find three-element sum closest to Zero2020-02-04 23:11:00
Print sorted unique elements of a given array2020-01-30 21:45:49
Given an array, print all unique subsets with a given sum.2020-01-26 22:16:21
Sum of length of subsets which contains given value K and all elements in subsets are less than equal to K.2020-01-20 21:59:47
Replace array elements with maximum element on the right.2020-01-18 20:26:28
Find all unique combinations of numbers (from 1 to 9 ) with sum to N2020-01-12 22:17:38
Number of Intervals in which given value lies2020-01-10 23:19:08
Activity Selection Problem2020-01-06 21:38:14
Find the sum of overlapping elements in two sets2020-01-04 21:16:53
Given two coordinates, Print the line equation2020-01-02 21:56:43
Check if Graph is Bipartite – Adjacency List using Breadth-First Search(BFS)2019-12-30 22:29:10
Articulation Points OR Cut Vertices in a Graph2019-12-28 13:07:06
Print all middle elements of the given matrix/2D array.2019-12-26 21:19:54
Check If Given Undirected Graph is a tree2019-12-24 21:53:37
Find the number of distinct Islands OR connected components.2019-12-22 20:58:19
Check the completeness of given binary tree | Set 2 – Using Level Order Traversal2019-12-20 12:50:19
Depth-First Search (DFS) in 2D Matrix/2D-Array – Recursive Solution2019-12-18 21:00:32
Numbers with prime set bits in a given range using Sieve of Eratosthenes Algorithm2019-12-16 22:10:46
Print All Paths in Dijkstra’s Shortest Path Algorithm2019-12-14 15:47:26
Hamming Distance between two given integers2019-12-12 21:32:06
Breadth-First Search (BFS) in 2D Matrix/2D-Array2019-12-10 20:43:34
Check the completeness of given binary tree | Set 1 – Using Node Count2019-12-08 12:36:18
Number of Islands using BFS2019-12-06 20:25:30
Find all the Armstrong numbers in the given range2019-12-04 21:48:33
Check if the given binary tree is Full or not.2019-12-02 14:56:32
Check if given undirected graph is connected or not2019-11-30 14:44:26
Check if Graph is Bipartite – Adjacency List using Depth-First Search(DFS)2019-11-28 15:07:24
Print boundary of given matrix/2D array.2019-11-26 21:11:14
Depth-First Search (DFS) in 2D Matrix/2D-Array – Iterative Solution2019-11-24 20:52:46
Longest substring with at most K unique characters2019-11-22 21:22:47
Collatz Conjecture – Maximum Steps takes to transform (1, N) to 1.2019-11-20 21:17:01
Given Graph – Remove a vertex and all edges connect to the vertex2019-11-18 14:37:51
Print Stack in reverse order.2019-11-16 21:36:18
Sort a given stack – Using Recursion2019-11-14 21:10:27
Given an array, Print sum of all subsets2019-11-12 20:59:23
Determine the given routing number belong to which bank2019-11-10 15:41:50
Check if interval is covered in given coordinates2019-11-08 20:48:40
Lexicographically previous permutation With One swap2019-11-06 23:01:11
Find all unique combinations of exact K numbers (from 1 to 9 ) with sum to N2019-11-04 21:27:11
Number’s Complement – 2 Approaches2019-11-02 20:56:52
Print all subsets of an array with a sum equal to zero2019-10-30 23:31:12
Social Network Problem2019-10-28 22:48:55
Maximum number edges to make Acyclic Undirected/Directed Graph2019-10-27 00:33:10
Evaluation of Prefix Expressions (Polish Notation) | Set 22019-10-24 22:03:52
Hamming Distance between two given strings2019-10-22 15:30:12
Breadth-First Search in Disconnected Graph2019-10-20 22:02:37
ZigZag OR Diagonal traversal in 2d array/Matrix using queue2019-10-18 22:43:43
Check if Number is divisible by its digits2019-10-16 19:51:17
Check if the given number is Armstrong number or not2019-10-14 23:17:43
Evaluation of Prefix Expressions (Polish Notation) | Set 12019-10-12 16:46:38
Minimum Boats Required to rescue people2019-10-10 21:36:39
Number of Islands2019-10-08 21:50:42
Minimum No of operations required to convert a given number to 1 – Integer Replacement Problem.2019-10-06 16:00:02
Evaluation of Postfix Expressions (Polish Postfix notation) | Set 22019-10-04 23:35:14
Evaluation of Postfix Expressions (Polish Postfix notation) | Set 12019-10-03 00:44:00
Find all the numbers in the range which has prime set bits.2019-09-30 20:31:04
Check if Graph is Bipartite – Adjacency Matrix using Depth-First Search(DFS)2019-09-28 23:25:58
Check if Arithmetic Expression contains duplicate parenthesis2019-09-26 21:08:50
Introduction to Bipartite Graphs OR Bigraphs2019-09-25 20:54:08
Reverse the Directed Graph2019-09-22 21:50:05
Round Price Problem2019-09-20 22:21:46
Smallest Number after Removing K digits2019-09-18 21:33:04
Find Third Smallest elements in a given array2019-09-16 22:08:13
Determine the order of Tests when tests have dependencies on each other2019-09-14 23:57:36
Implement Graph Using Map – Java2019-09-12 20:30:54
Find the maximum number present in a String2019-09-10 20:01:59
Count number of subgraphs in a given graph2019-09-08 20:18:57
Reverse a Stack using recursion – In Place (Without using extra memory)2019-09-06 22:38:40
Check if given an edge is a bridge in the graph2019-09-04 20:59:33
Convert Prefix to Postfix Expression2019-09-02 23:01:26
Convert Roman Number to Integer2019-08-31 01:35:12
Sort a given stack – Using Temporary Stack2019-08-30 19:49:53
Convert Postfix to Prefix Expression2019-08-28 20:59:02
K-Means Algorithm2019-08-24 22:40:20
Convert Integer to Roman2019-08-24 22:16:44
String to Integer (AtoI – ASCII to Integer) – Recursive Solution2019-08-22 23:40:21
Grouping of Anagrams2019-08-20 23:01:05
Print Processes and its messages from a given log file2019-08-18 23:49:12
Linear Search vs Binary Search2019-08-16 23:52:54
Count the number of nodes in a given binary tree2019-08-14 22:40:21
Sieve of Eratosthenes – Find all Prime Numbers less than equal to N | Set 22019-08-12 22:56:32
Longest contiguous character in a given String – O(N) Solution2019-08-10 23:42:43
Convert Postfix to Infix Expression2019-08-08 23:27:35
Collatz Conjecture – Steps to transform Number to 12019-08-06 23:48:10
String to Integer (AtoI – ASCII to Integer)2019-08-04 01:07:26
Find all Prime Numbers less than equal to N | Set 12019-07-28 00:42:00
Longest substring with at most two unique characters2019-07-24 00:14:11
Monotone Increasing Digits2019-07-15 23:33:05
Convert Prefix to Infix Expression2019-06-22 16:46:07
Convert Infix to Prefix Expression2019-06-12 23:49:19
Find third largest element in a given array2019-05-29 20:21:18
Find duplicates Characters in the given String2019-05-21 20:32:57
Max Flow Problem – Ford-Fulkerson Algorithm2019-05-16 22:05:48
Sum of all Unique elements in a given array2019-05-07 21:13:04
Java program to find the largest element in array2019-05-03 00:09:03
Convert Infix to Postfix Expression2019-04-23 23:28:26
Find three smallest elements in a given array2019-04-16 00:07:24
Evaluation of Infix expressions2019-04-09 00:18:00
Stack Java Class – Explained2019-04-03 21:59:05
Least Recently Used (LRU) Cache – Using LinkedHashSet and Deque | Set 22019-04-01 21:59:32
Merge K sorted Linked List – Using Priority Queue2019-03-26 21:11:02
Infix, Postfix and Prefix Notations/Expressions2019-03-24 23:20:58
Count Set bits in a given Number2019-03-20 23:32:49
Check if array contains all unique or distinct numbers.2019-03-16 23:47:03
Product of all Unique elements in a given array.2019-03-03 22:36:36
Valid Multiple Parentheses2019-02-22 00:34:03
Reverse a given number – Java Code2019-02-17 23:13:30
Check if given number is perfect square – O(√N) Solution2019-02-09 13:48:09
Least Recently Used (LRU) Cache – Using HashMap and Doubly Linked List | Set 12019-02-05 22:59:48
Find first three largest elements in a given array2019-02-03 01:00:24
Selection Sort – Java Implementation2019-01-29 22:46:26
Print Number with its Sign in Java2019-01-28 00:55:46
Find the nearest building which has bike | Find nearest specific vertex from source in a graph.2019-01-26 23:13:34
Valid Brackets – Part 2 | Stack Method2019-01-24 23:02:32
Find the roots of Quadratic Equation – Java Program2019-01-23 20:52:50
Given two strings validate the output string2019-01-21 20:33:39
Generate all the strings of length n from 0 to k-1.2019-01-13 22:53:11
Find two smallest elements in a given array2019-01-05 23:41:24
Front and Back Search in an Array2018-12-30 01:09:19
Print all Unique elements in a given array2018-12-19 01:50:07
Multiply with power of 2 without using pow() or * operator2018-12-16 21:16:20
Find Number of reverse pairs in an array2018-12-15 14:10:38
Find first two largest elements in a given array2018-12-13 00:04:40
Calculate Logn base r – Java Implementation2018-12-11 01:00:54
Max Flow Problem – Introduction2018-12-09 20:35:40
Dijkstra Algorithm Implementation – TreeSet and Pair Class2018-11-21 15:10:26
Java Program to find Sum the elements of an Array2018-11-21 14:33:54
Insertion Sort – Java Implementation2018-11-19 21:59:01
Find Largest and Smallest word in a given String2018-11-03 23:18:30
Check if Given Number is power of 2.2018-10-27 18:26:37
Rotate the given array in cycles2018-09-21 18:22:28
Heap Sort – Java Implementation2018-09-11 21:21:41
Print First n numbers in Fibonacci Series2018-09-05 20:00:55
Find the Area and Perimeter of Rectangle – Java Program2018-09-02 00:01:41
Find no of reverse pairs in an array which is sorted in two parts in O(N)2018-08-26 21:03:09
Reverse the given String using Stack2018-08-22 22:10:50
Stack Data Structure – Introduction and Implementation2018-08-21 00:03:08
Dijkstra’s – Shortest Path Algorithm (SPT) – Adjacency List and Priority Queue – Java Implementation2018-08-17 22:46:01
Bubble Sort and Optimized Bubble Sort- Java Implementation2018-08-15 22:01:39
Find the Area of Triangle using base and height – Java Program2018-08-12 19:43:10
Get the Sum of Digits in a number till it become a single digit2018-08-08 23:49:57
Calculate Log2n without using built-in function2018-08-05 13:09:27
Check if given number is Prime – O(√N) Solution – Java Program2018-08-04 12:30:15
Print First N Prime Numbers – Java Code2018-08-02 22:05:53
Print My IP Address – Java Code2018-07-31 23:04:52
Find the Circumference of a Circle – Java Program2018-07-30 22:51:28
Check if two Strings are equal without using built-in function – Java2018-07-30 22:36:52
Remove Vowels from a given String2018-07-29 22:45:21
Linear Search Algorithm2018-07-28 21:07:29
Dijkstra’s – Shortest Path Algorithm (SPT) – Adjacency List and Min Heap – Java Implementation2018-07-25 21:38:54
Floyd’s Triangle – Java Implementation2018-07-24 23:31:44
Print Numbers from 1 to N without using loop2018-07-17 21:23:15
Swap two numbers using Bitwise XOR Operator2018-07-16 00:01:20
Java Program to determine if Given Year is Leap Year2018-07-13 21:00:32
Find number of Distinct Permutations of a String2018-07-10 20:09:56
Find the Area of a Circle – Java Program2018-07-08 00:52:58
Dijkstra’s – Shortest Path Algorithm (SPT) – Adjacency Matrix – Java Implementation2018-07-05 21:32:16
Fizz Buzz Challenge – Java Implementation2018-07-02 20:32:18
Divide with power of 2 without using pow() or / operator2018-06-29 21:50:20
Maximum Difference between two elements in array – Largest Gap Problem2018-06-27 23:26:53
Minimum number of guesses needed to find a specific number2018-06-25 00:24:15
Left Shift (<<) and Right Shift (>>) Operators2018-06-22 21:31:05
Dijkstra’s – Shortest Path Algorithm (SPT)2018-06-20 11:08:44
Replace all vowels with next consonant in a given string2018-06-18 00:08:11
Find the Area of a Triangle Using coordinates2018-06-16 20:00:23
Java Program to find if Triangle can be formed using given 3 sides2018-06-16 14:08:18
Convert Number to base 3 String Representation2018-06-16 13:59:13
Find the Area of a Triangle Given Three Sides – Heron’s Formula2018-06-09 13:29:49
Find Factorial of a given Number2018-06-09 12:39:24
Reverse a String using Recursion2018-06-09 12:10:26
Find Sum of all Digits of a Number2018-06-09 12:04:31
Print maximum occurring character in a String2018-06-09 00:37:38
Kruskal’s Algorithm – Minimum Spanning Tree (MST) – Complete Java Implementation2018-05-29 21:03:52
Introduction to Minimum Spanning Tree (MST)2018-05-17 00:04:11
Prim’s – Minimum Spanning Tree (MST) |using Adjacency List and Priority Queue without decrease key in O(ElogV)2018-05-15 20:19:52
Prim’s – Minimum Spanning Tree (MST) |using Adjacency List and Priority Queue with decrease key2018-05-13 15:56:05
Prim’s – Minimum Spanning Tree (MST) |using Adjacency List and Min Heap2018-05-07 19:47:49
Prim’s – Minimum Spanning Tree (MST) |using Adjacency Matrix2018-04-25 22:29:57
Prim’s Algorithm – Minimum Spanning Tree (MST)2018-04-21 21:40:54
Graph – Find Cycle in Undirected Graph using Disjoint Set (Union-Find)2018-04-15 13:23:01
Disjoint Set | Union-Find Algorithm – Union by rank and path compression2018-04-12 00:28:01
Disjoint Set Data Structure – Union Find Algorithm2018-04-07 23:27:03
Graph – Count all paths between source and destination2018-04-05 21:07:39
Graph – Find Number of non reachable vertices from a given vertex2018-04-02 20:19:14
Graph – Detect Cycle in a Directed Graph using colors2018-03-29 22:21:43
Graph – Detect Cycle in an Undirected Graph using DFS2018-03-26 23:17:41
Graph – Detect Cycle in a Directed Graph2018-03-21 21:54:43
Graph – Software Installation Problem2018-03-18 19:54:38
Snake and Ladder Problem2018-03-14 21:14:11
Weighted Graph Implementation – JAVA2018-03-13 22:23:16
Graph – Depth First Search in Disconnected Graph2018-03-11 13:43:04
Topological Sort2018-03-06 22:16:05
Graph – Depth First Search using Recursion2018-03-04 10:13:52
Graph Implementation – Adjacency Matrix | Set 32018-03-01 22:51:52
Java Pair Class2018-02-25 20:43:10
Graph Implementation – Adjacency List – Better| Set 22018-02-22 22:30:55
Minimum Copy Paste Operations2018-02-17 18:39:55
Count and print all Subarrays with product less than K in O(n)2018-02-12 23:10:46
Sliding Window Algorithm (Track the maximum of each subarray of size k)2018-02-10 18:38:00
Deque Implementation – Java2018-02-08 22:29:57
Print all sub sequences of a given String2018-02-05 22:23:27
Graph – Print all paths between source and destination2018-02-04 13:48:30
Graph – Depth First Traversal2018-02-01 22:19:03
Print all sub sequences of a given array2018-01-28 22:34:36
Print all substrings of a given string2018-01-26 00:08:36
Sum of all sub arrays in O(n) Time2018-01-22 18:09:42
Print all subarrays of a given array2018-01-19 17:47:19
Text Justification Problem (OR Word Wrap Problem)2018-01-16 17:37:39
Dynamic Programming – Egg Dropping Problem2018-01-13 22:24:22
Nuts & Bolts Problem (Lock & Key problem)2018-01-10 20:29:28
Divide and Conquer – Rearrange array elements in special order2018-01-05 20:18:16
Dynamic programming – Printer Problem2018-01-01 12:57:02
Remove Duplicates from a string2017-12-28 19:12:11
Find median of two sorted arrays of same size2017-12-23 14:01:30
Dynamic programming – Minimum Jumps to reach to end2017-12-17 13:42:17
Dynamic programming – Remove Boxes Problem2017-12-03 14:02:46
Find two non-repeating numbers in an array in O(n) time and O(1) space2017-10-29 09:24:47
Number of bit to be flipped to convert one number to another.2017-09-14 20:51:42
Separate even and odd integers in a given array2017-09-12 22:20:38
Find three elements in an array that sum to a zero.2017-09-11 22:10:00
All elements appears thrice and one element appears once. Find that element in O(n) time and O(1) space2017-09-07 19:56:04
Separate 0’s and 1’s in a given array2017-09-05 22:14:03
Find local minimum or local maximum in O(1).2017-09-04 14:27:54
Find three elements in an array that sum to a given value2017-09-03 22:09:56
Majority Element- Boyer–Moore majority vote algorithm2017-09-01 19:31:15
Majority Element – Part 12017-09-01 19:23:38
Find the local minima in a given array2017-09-01 19:15:53
Check whether the given number is a perfect square2017-08-26 23:15:50
Check if array is sorted using recursion2017-08-26 23:07:00
Find the Index from which 0 starts2017-08-26 23:01:16
Find the increasing OR decreasing point in an array2017-08-26 22:51:47
Find the only element in array which appears only once2017-08-26 22:43:36
Algorithm to calculate power(k,n).2017-08-26 22:35:13
Find remainder without using modulo operator2017-08-26 22:27:31
Swap two numbers without using extra variable2017-08-26 22:21:01
Number of 1’s in bit representation of a number2017-08-26 17:23:17
Stock Single Sell Problem – O(n) Solution2017-08-26 17:12:14
Maximum Subarray OR Largest Sum Contiguous Subarray Problem – Divide and Conquer2017-08-26 16:59:09
Maximum difference between two elements where larger element appears after the smaller element2017-07-30 16:24:30
Find the right most unset bit OR zero bit of a number2017-07-30 16:16:12
Find the two repeating elements in a given array | 6 Approaches2017-07-24 19:07:06
Find the right most set bit of a number2017-07-23 14:39:04
Find two elements whose sum is closest to zero2017-07-09 18:50:31
Find the element which appears maximum number of times in the array.2017-06-26 20:06:29
Find duplicates in an given array in O(n) time and O(1) extra space.2017-06-18 12:08:44
Find the last non repeating character in a given string.2017-06-11 19:21:28
Find the last repeating character in a given string.2017-05-29 20:34:49
Find the first non repeating character in a given string2017-05-27 15:08:59
Find the first repeating character in a given string2017-03-08 00:09:32
k-Nearest Neighbors2016-12-30 00:01:34
Find longest Snake sequence in a given matrix2016-08-08 00:24:22
Dynamic Programming – Count all paths in 2D Matrix with Obstructions in it2016-06-20 19:37:31
Dynamic Programming – Count all paths from top left to bottom right of a mXn matrix2016-06-19 10:29:43
Reverse the given Array without using built in function2016-06-19 10:17:23
Print All Diagonals of a given matrix2016-06-17 22:55:55
Dynamic Programming – Edit Distance Problem2016-05-14 20:11:10
Dynamic Programming – Coin In a Line Game Problem2016-05-08 18:08:55
Dynamic Programming – Box Stacking Problem2016-04-17 17:23:51
Dynamic Programming – Split the String into Minimum number of Palindromes.2016-04-10 12:20:39
Dynamic Programming – Highway Billboard Problem2016-04-05 14:20:47
Dynamic Programming – Maximum Subarray Problem2016-04-03 19:00:09
Kadane’s Algorithm – Maximum Subarray Problem2016-03-31 01:18:59
Convert Binary Tree into Threaded Binary Tree2016-03-24 18:55:05
Double Threaded Binary Tree Complete Implementation2016-03-21 20:53:09
Single Threaded Binary Tree Complete Implementation2016-03-19 16:56:28
Introduction to Threaded Binary Tree2016-03-19 16:33:38
Implement Stack Using Linked List2016-03-19 13:18:13
Doubly Linked List Complete Implementation2016-03-18 20:34:04
Circular Linked List Complete Implementation2016-03-15 23:18:33
Swap Nodes in pairs in a Linked List by changing links2016-03-13 20:09:38
Convert BST to Greater Sum Tree2016-02-27 20:45:26
Shortest Range in K-sorted Lists2016-02-19 22:54:24
Reverse Alternative ‘k’ nodes in a Linked List.2016-02-18 19:25:06
Reverse a Linked List in groups of given size ‘K’2016-01-03 20:47:34
Generate Maximum revenue by selling K tickets from N windows2016-01-03 20:22:26
Get the Sum of all left leaves in a Binary tree2015-12-06 11:44:36
Convert binary tree to its Sum tree2015-12-06 11:32:11
Binary Tree-Postorder Traversal – Non Recursive Approach2015-12-05 14:57:45
Binary Tree – Preorder Traversal – Non Recursive Approach2015-12-05 12:33:53
Binary Tree-Inorder Traversal – Non Recursive Approach2015-12-04 23:59:57
Delete the Binary Tree2015-12-04 23:25:34
Search the Element in a binary tree – With and Without Recursion2015-12-04 23:10:45
Tree Traversals2015-11-08 13:01:11
Find the Size of a Binary Tree without Recursion2015-11-08 12:33:19
Dynamic Programming — Longest Palindromic Subsequence2015-08-04 22:15:53
Dynamic Programming – Maximum Product Cutting Problem.2015-07-11 10:16:50
Dynamic Programming – Minimum Numbers are Required Whose Square Sum is Equal To a Given Number2015-07-03 21:35:20
Dynamic Programming – Longest Common Substring2015-06-29 21:29:51
Dynamic Programming – Longest Common Subsequence2015-06-28 11:43:44
Dynamic Programming – Rod Cutting Problem2015-06-27 17:59:36
Dynamic Programming – Coin Change Problem2015-06-27 15:06:04
Dynamic Programming – Minimum Cost Path Problem2015-06-14 17:51:12
All N Length Strings from Given String of Length K2015-06-10 21:40:01
Generate Well Ordered Passwords of a Given Length K2015-06-10 21:34:53
Print All N Length Strings from Given Number K2015-06-10 21:19:49
Print All Possible Subsets with Sum equal to a given Number2015-06-08 20:56:00
Dynamic Programming – Maximum size square sub-matrix with all 1s2015-05-10 13:47:45
Dynamic Programming – Subset Sum Problem2015-05-10 13:34:32
The Word Break Problem2015-05-10 13:15:51
Dynamic Programming – Longest Increasing Subsequence2015-05-10 02:14:14
Backtracking – Knight’s Tour Problem2015-05-10 01:28:37
Backtracking – Search a Word In a Matrix2015-05-10 01:09:13
Backtracking – N Queens Problem – Better Solution2015-05-10 00:55:54
Backtracking – N Queens Problem2015-05-10 00:43:48
Find the Kth Smallest/Largest Element in an Array2015-05-10 00:31:22
Priority Queue in Data Structure2015-05-10 00:21:29
Find the Second Largest Element in an Array2015-05-09 23:52:38
Breadth-First Search/Traversal in a Graph.2015-05-09 23:44:09
Breadth-First Search/Traversal in a Binary Tree2015-05-09 23:16:32
Sort Names by their Last Names.2015-05-08 18:45:42
Backtracking – Rat In A Maze Puzzle2015-04-13 15:03:35
Backtracking – SUDOKU Solver2015-03-16 20:24:30
Introduction To Backtracking Programming2015-03-16 20:13:31
Dynamic Programming – Stairs Climbing Puzzle2015-03-16 20:04:44
Dynamic Programming – Minimum Coin Change Problem2015-03-16 19:57:27
Introduction To Dynamic Programming – Fibonacci Series2015-03-16 19:44:12
Merge K Sorted Arrays2015-03-14 15:33:24
Find the Deepest Left Node in a Binary Tree.2015-03-14 15:24:00
Find a Number occurring odd number of times in a Given array2015-03-14 15:11:50
Rearrange the Array of Given Range N, such that A[i]=i2015-03-14 15:06:50
Find a Missing Number From a Sequence of Consecutive Numbers | XOR Method2015-03-14 14:44:19
Find the Max element in a Given Binary Tree2015-03-14 14:40:48
Populate Next Siblings Pointers in a Given Binary Tree OR Populate Next Right Pointers in Each Node2015-03-14 14:36:20
Check If One Binary is Mirror Tree of another Binary Tree.2015-03-14 14:21:10
Print All Paths From Root In a Binary Tree Whose Sum is Equal to a Given Number2015-03-14 14:14:08
Diameter Of a Binary Tree2015-03-14 14:08:57
Reverse Level Order Traversal2015-03-14 03:02:16
Find the Deepest Node in a Binary Tree.2015-03-14 02:15:48
Find the Height of a tree without Recursion2015-03-14 02:11:36
Print All The Full Nodes in a Binary Tree2015-03-14 02:02:33
Binary Min-Max Heap Implementation2015-02-22 17:21:28
Magic Index – Find Index In Sorted Array Such That A[i] = i.2015-02-22 17:06:00
Find numbers which are palindrome in both their decimal and octal Representations2015-02-22 16:02:07
Find All the Well Ordered Permutations of a Given String.2015-02-22 14:35:09
Find Increasing Triplet Sub-sequence2015-02-22 14:19:19
Construct a Special Triangle from a Given Array2015-02-22 14:10:01
Colorful Numbers2015-02-22 00:14:01
Print All the Subsets of a Given Set (Power Set)2015-02-21 23:59:01
Goldbach’s Conjecture2015-02-21 23:50:23
Convert Decimal into Irreducible Fraction2015-02-21 00:21:16
Clock Angle Problem2015-02-20 19:28:47
Print All Combinations of subset of size K from Given Array2015-02-20 19:07:29
Track the Maximum Element in a Stack.2015-02-16 16:24:07
Print All Possible Valid Combinations Of Parenthesis of Given ‘N’2015-02-05 14:14:38
Graph Representation – Adjacency Matrix and Adjacency List2015-02-02 17:38:37
Counting Sort2015-02-02 16:21:13
Towers Of Hanoi2015-02-02 16:15:09
Generate All Strings of n bits.2015-02-01 15:57:18
Find The Missing Duplicate in a Given Array.2015-02-01 15:40:25
Sort 3 Integers without using if condition OR use only Max() function.2015-02-01 15:30:49
Euclidean algorithm – Greatest Common Divisor(GCD)2015-01-31 23:46:08
Implement Queue Using Stacks2015-01-31 23:38:08
Alternate Splitting of a given Linked List2015-01-31 23:03:46
Reverse The Doubly Linked List2015-01-31 21:48:00
Swap Kth Node from the front with the Kth Node from the End2015-01-31 21:25:09
Print the Bottom View of the Binary Tree.2015-01-30 03:38:05
Delete X Nodes After Y Nodes In a Linked List2015-01-29 13:11:27
Merge Sort in a Linked list2015-01-29 12:55:27
Merge a Linked list into another Linked List at Alternate Positions.2015-01-05 20:22:52
AVL Tree – Insertion2014-12-30 23:10:35
Construct a binary tree from given Inorder and Level Order Traversal2014-12-30 21:46:58
Construct Binary Search Tree from a given Preorder Traversal Using Stack (Without Recursion)2014-12-30 05:55:03
Construct Binary Search Tree from a given Preorder Traversal using Recursion2014-12-30 05:45:40
Print The Top View of a Binary Tree2014-12-30 05:29:07
Construct a Binary Tree from Given Inorder and Depth-First-Search.2014-12-30 05:16:11
Depth First Search/Traversal in Binary Tree2014-12-30 05:03:06
Inorder Predecessor and Successor in Binary Search Tree2014-12-29 22:08:55
Check if Array Contains All Elements Of Some Given Range2014-12-29 20:44:38
Check if Array is Consecutive Integers2014-12-29 20:37:11
Find the subarray with sum to a Given Value.2014-12-29 20:28:35
In an Array, find the Smallest Subarray with Sum Greater than the Given Value2014-12-29 20:18:37
Rearrange Positive and Negative Elements at Alternate Positions in an Array In O(1) Extra Space2014-12-28 06:21:34
Find intersection between Two Sorted Arrays.2014-12-28 06:09:47
Find Kth Smallest or Largest element in an Array.2014-12-28 06:02:44
Given an array arrA[], find the maximum j – i such that arr[j] > arr[i].2014-12-28 05:53:26
Find All Elements in an Array which appears more than N/K times, N is Array Size and k is a Number.2014-12-28 03:15:17
Search an Element in a Rotated Sorted Array2014-12-28 02:53:10
Print All The Nodes Which are X distance from the Given Node2014-12-08 23:37:27
Print All The Nodes Which are X distance from the Leaf Nodes2014-12-08 23:24:13
Print All The Nodes Which are X distance from the Root2014-12-08 23:16:50
Find the Distance between Two Nodes of a Binary Tree.2014-12-08 23:05:02
Find The Distance From Root To Given Node of a Binary Tree.2014-12-08 22:55:07
Construct a binary tree from given Inorder and Postorder Traversal2014-12-08 22:44:15
Print the Vertical Sum in binary Tree .2014-12-08 22:19:30
Print the Binary Tree in Vertical Order Path.2014-12-08 22:11:03
Lowest Common Ancestor in a Binary Tree (Not Binary Search Tree).2014-11-18 08:52:45
Lowest Common Ancestor in a Binary Search Tree.2014-11-18 08:28:54
Make a Binary Tree from Given Inorder and Preorder Traveral.2014-11-18 08:06:33
Given a binary tree, find out the maximum sum of value from root to each leaf.2014-11-18 07:50:13
Reverse Alternate levels of a given Binary Tree.2014-11-18 07:28:37
Given a Sorted Singly Linked List Array, Convert it into a Balanced Binary search Tree.2014-11-18 07:03:24
Given a binary tree, Convert it into its Mirror Tree2014-11-18 03:46:41
Given a binary tree, Print All the Nodes that don’t have Siblings.2014-11-18 02:46:53
Convert a Sorted Doubly Linked List to Balanced BST.2014-11-18 02:30:44
Given a binary tree, Find the Maximum Path Sum between Any Two Leaves2014-11-18 01:00:34
Print Left View of a given binary tree2014-11-18 00:46:23
Print Right View of a given binary tree2014-11-17 23:33:25
In a Binary Tree, Check if Two nodes has the same parent or are siblings2014-11-17 23:12:16
In a Binary Tree, Check if two nodes are Cousins2014-11-17 22:46:45
Check if Two BST’s are Identical2014-11-17 21:45:02
Print Paths from root to all leaf nodes in a binary tree.2014-11-17 21:14:09
Print All The Permutations Of a String2014-11-14 22:06:29
Sort an Given Array in the order defined by another array2014-11-14 21:02:52
Sort an Array – odd numbers appear first in ascending order followed by the even numbers in descending order.2014-11-11 08:08:33
Print All Nodes Between Two Given Levels2014-11-11 07:54:34
Find the maximum width of a binary tree2014-11-11 05:23:43
Find the number of occurrences of a number in a given sorted array.2014-11-11 03:14:09
Find all common numbers in given three sorted arrays.2014-11-11 03:05:11
Level Order Traversal in Zig Zag pattern OR Print in Spiral Pattern2014-11-10 20:04:05
Find the first repeated element in an array by its index2014-11-10 18:58:58
Minimum number that cannot be formed by any subset of an array2014-11-10 18:21:30
Determine whether given binary tree is binary search tree(BST) or not2014-09-27 20:58:54
Find the Size of the Binary Tree2014-09-27 19:12:28
Given two binary trees, check if one binary tree is a subtree of another2014-09-27 18:18:22
Print a path from Root to Node in Binary Tree2014-09-27 18:04:50
Inorder Successor in Binary Search Tree without Using Parent link2014-09-27 16:46:09
Inorder Successor in Binary Search Tree Using Parent link2014-09-27 16:46:01
Inorder Successor in Binary Tree2014-09-27 16:45:50
Sorted Array to Binary Search Tree of Minimal Height2014-09-27 15:51:19
In a Binary Tree, Create Linked Lists of all the nodes at each depth.2014-09-22 21:38:14
Level Order Traversal, Print each level in separate line.2014-09-21 08:03:34
Find whether if a Given Binary Tree is Balanced?2014-09-21 01:16:54
Get the Height of a Node in a Binary Tree2014-09-20 17:05:05
Find the Maximum Depth OR Height of a Binary Tree2014-09-19 15:53:16
Add two numbers represented by a linked list, Numbers are Stored in FORWARD order2014-09-16 22:59:40
Add two numbers represented by a linked list, Numbers are Stored in REVERSE order2014-09-16 22:28:49
Reverse the binary representation of a number.2014-09-16 20:32:30
Binary Search Tree (BST) Complete Implementation.2014-09-16 00:38:04
Reverse a Linked List – Part 22014-09-14 03:13:55
Swap Every Kth Node in a LinkedList2014-09-14 03:02:40
Delete a Node in the Middle of a linked list, Given only access to that Node2014-09-12 17:16:37
Find the n’th Node from the end of a given Linked List2014-09-12 06:40:00
Remove Duplicates from an Unsorted Linked list2014-09-11 17:06:30
Check if one string is Rotation of another string2014-09-09 23:29:04
String Compression using count of repeated characters – Run Length Encoding2014-09-09 02:49:24
Replace all spaces in a String with ‘%20’2014-09-08 05:26:30
Find Whether Two Strings are Permutation of each other2014-09-08 05:19:13
Find Intersection Point in Two Linked List2014-09-06 17:41:44
Find the Loop in a Linked list, find its length and Break the Loop2014-09-05 21:49:36
Reverse a Linked List2014-08-28 16:54:29
Count All Paths from Top left to bottom right in Two Dimensional Array including Diagonal Paths2014-08-25 04:11:48
Print All Paths from Top left to bottom right in Two Dimensional Array2014-08-13 14:43:45
Merge or Combine Two Sorted Linked Lists2014-08-12 14:58:31
Singly Linked List Implementation2014-08-12 14:34:27
Rearrange Positive and Negative Numbers of Array On Each Side in O(nlogn)2014-08-04 17:50:28
Find The Longest Sequence Of Prefix Shared By All The Words In A String2014-08-04 17:37:31
Print All Elements of Two Dimensional Array in Spiral2014-08-04 17:11:31
Find a pair of numbers from an array whose sum equals k2014-08-04 02:01:38
Check If String has All Unique Characters2014-08-03 05:49:14
Quick Sort Implementation2014-08-03 02:22:30
Valid or Well Formed Parentheses | Part – 12014-07-23 19:08:54
Find an Element in 2 dimensional sorted array2014-07-20 22:27:52
Find Whether Given String is palindrome or Not.2014-07-20 22:19:24
Find a peak element in a Given Array2014-07-20 22:12:23
Find two Missing Numbers in a Sequence of Consecutive Numbers2014-07-20 22:05:30
Find a Missing Number From a Sequence of Consecutive Numbers2014-07-20 22:00:05
Hash Table Implementation2014-07-20 21:54:06
Merge Sort – Updated – Most Efficient ways to Implement2014-07-20 21:41:14
Binary Search2014-07-20 15:35:10