ProDeveloperTutorialonAugust 28, 2026 Recursion: Given a number, return the sum of digit Problem Statement: You are given a number, you need to return the sum of digits. Example: Input: n = 123 Output: 6 Solution Explanation: We…
ProDeveloperTutorialonAugust 28, 2026 Recursion: Remove K adjacent duplicate in a string Problem Statement: You are given a string and a value k. You need to remove k adjacent duplicate from the array. Example: Input: s =…
ProDeveloperTutorialonAugust 28, 2026 Recursion: Given an array, generate all sub arrays using recursion Problem Statement: You are given an array, you need to generate all sub arrays of the given array Example: Input: arr = {1, 2, 3} Output: [1],…
ProDeveloperTutorialonAugust 28, 2026 Recursion: Remove adjacent duplicates in the string. Problem Statement: You are given a string, you need to remove adjacent duplicate. Example: Input: s = "abbaca" Output: s =…
ProDeveloperTutorialonAugust 28, 2026 Recursion: Given a string, find the occurrence of first uppercase letter in the string. Problem Statement: You are given a string, you need to find the first upper case letter using recursion. Example: Input: proDeveloperTutorial…
ProDeveloperTutorialonAugust 28, 2026 Recursion: Given a number, generate all binary strings. Problem Statement: You are given a number, you need to generate all binary strings that do not have consecutive 1s and in increasing order…
ProDeveloperTutorialonAugust 28, 2026 Recursion: Given a linked list, find the middle element recursively Problem Statement: You are given a LL, you need to find the middle element recursively. Example: Input: 1 -> 2 -> 3 -> 4 -> 5…
ProDeveloperTutorialonAugust 28, 2026 Recursion: You are given a stack, reverse it using recursion Problem Statement: You are given a stack, you need to reverse it using recursion. You are allowed to use all the stack operation Example:…
ProDeveloperTutorialonAugust 28, 2026 Recursion: Given a stack, delete the middle element using recursion Problem Statement: You are given a stack, you need to delete the middle element using recursion. Example: Input: s = {1, 2, 3, 4, 5} Output: s…
ProDeveloperTutorialonAugust 27, 2026 Recursion: Given a decimal number, convert into binary number using recursion Problem Statement: Given a decimal number, convert into binary number using recursion Example: Input: n = 7 Output: 111 Solution Explanation:…