ProDeveloperTutorialonAugust 29, 2026 Binary Search Trees: Check If Preorder Traversal Is Valid BST Problem Statement: You are given a array, you need to check if array can be represented as pre-order of BST. BST is a tree that satisfies… Discover More
ProDeveloperTutorialonAugust 29, 2026 Binary Search Trees: Given a sorted linked list into binary search tree Problem Statement: Given a sorted linked list into binary search tree Example: Input: 1 -> 2 -> 3 Output: 2 / \ 1 3 [[2], [1,3]] … Discover More
ProDeveloperTutorialonAugust 28, 2026 Hashing: Given an array, you need to count the frequency if the array elements Problem Statement: You are given an array, you need to find the frequency of each distinct element. Example: Input: arr = [1, 2, 1, 2, 3, 4,… Discover More
ProDeveloperTutorialonAugust 28, 2026 Hashing: Given an array, count all the subsets with even numbers and are distinct Problem Statement: You are given an array with repeated integers, you need to count all the subsets which has only even numbers and all are… Discover More
ProDeveloperTutorialonAugust 28, 2026 Hashing: Given an array, you need to find the missing number Problem Statement: Given an array of size n in the range [0, n, you need to find the missing number. Example: Input: s = [0, 3, 1] Output: [2]… Discover More
ProDeveloperTutorialonAugust 28, 2026 Hashing: Given an array and a value k, return top k frequent elements Problem Statement: Given an array and a value k, return top k frequent elements. Example: Input: arr = [1, 2, 1, 2, 2, 2, 1], k = 2 Output:… Discover More
ProDeveloperTutorialonAugust 28, 2026 Hashing: Given 2 arrays, and a value x, you need to find the pairs sum equal to the given value of x. Problem Statement: You are given 2 sorted arrays and a value k. You need to find all pairs from both the array whose value is equal to x.… Discover More
ProDeveloperTutorialonAugust 28, 2026 Hashing: Given an array, find the element that occurs odd number of times Problem Statement: Given an array, find the element that occurs odd number of times Example: Input: arr = [1, 1, 1, 2, 2, 3, 3] Output: 1… Discover More
ProDeveloperTutorialonAugust 28, 2026 Hashing: Given an array, find the majority element Problem Statement: You are given an array of repeated numbers. You need to return all the numbers that repeats [n/3] times Example: Input: arr… Discover More
ProDeveloperTutorialonAugust 28, 2026 Hashing: Given an array, find the first missing positive number Problem Statement: You are given an array, you need to return the first smallest positive integer. You need to do it in O(n) and O(1) space.… Discover More