Tutorials
Courses
Data Structure
Java
Python
HTML
Interview Preparation
DSA
Practice Problems
C
C++
Java
Python
JavaScript
Data Science
Machine Learning
Courses
Linux
DevOps
SQL
Web Development
System Design
Aptitude
GfG Premium
Similar Topics
Web Technologies
37.4K+ articles
DSA
22.8K+ articles
Misc
8.8K+ articles
Mathematical
7.8K+ articles
Arrays
6.5K+ articles
Competitive Programming
3.3K+ articles
Strings
3.3K+ articles
Dynamic Programming
1.6K+ articles
Recursion
1.0K+ articles
Combinatorial
707+ articles
Memoization
60 posts
Recent Articles
Popular Articles
Length of Longest Common Subsequence with given sum K
Last Updated: 03 April 2023
Given two arrays a[] and b[] and an integer K, the task is to find the length of the longest common subsequence such that sum of elements is equal to K.Examples:Input: a[]...
read more
Dynamic Programming
Recursion
DSA
Arrays
subsequence
LCS
Memoization
Maximise sum of product of pairs by choosing subsequence of same length from given Arrays
Last Updated: 26 December 2023
Given two integer arrays A[] and B[] of different length N and M respectively, the task is to choose any subsequence of same length from each array such that sum of produc...
read more
Dynamic Programming
Recursion
Geeks Premier League
Geeks-Premier-League-2022
DSA
Arrays
subsequence
Memoization
Minimize square sum of given Arrays by swapping elements at same indices
Last Updated: 23 February 2023
Given two arrays arrA[] and arrB[] containing N integers each. Perform the following operation any number of times (possibly zero):Select any index i (0 = i = N-1) andSwap...
read more
Dynamic Programming
Greedy
Competitive Programming
Geeks Premier League
Geeks-Premier-League-2022
DSA
Arrays
Memoization
Minimum cost to delete characters from String A to remove any subsequence as String B
Last Updated: 27 July 2023
Given two strings A and B of size N and M respectively, where B is a sub-sequence of A and an array arr[] of size N, where arr[i] is the cost to delete ith character from ...
read more
Strings
Dynamic Programming
Recursion
Geeks Premier League
Geeks-Premier-League-2022
DSA
subsequence
Memoization
Maximum Path sum in a N-ary Tree
Last Updated: 02 December 2024
Given an undirected tree with n nodes numbered from 1 to n and an array arr[] where arr[i] denotes the value assigned to (i+1)th node. The connections between the nodes ar...
read more
Tree
Recursion
Picked
DSA
DFS
n-ary-tree
Memoization
What is Memoization? A Complete Tutorial
Last Updated: 29 November 2024
In this tutorial, we will dive into memoization, a powerful optimization technique that can drastically improve the performance of certain algorithms. Memoization helps by...
read more
Dynamic Programming
DSA
Memoization
DSA Tutorials
Longest Substring of given characters by replacing at most K characters for Q queries
Last Updated: 29 November 2022
Given a string s of length N, and Q queries, each of type (K, C) where K is an integer C is a character, the task is to replace at most K characters of the string by C and...
read more
Strings
Dynamic Programming
DSA
Memoization
Count ways to split string into K Substrings starting with even digit and min length M
Last Updated: 29 January 2025
Given a string s of length n consisting of digits from '0' to '9'. The task is to determine the total number of possible ways to partition the string into k substrings suc...
read more
Misc
Strings
Dynamic Programming
DSA
Memoization
substring
Minimum sum of a set of nodes of Tree following given conditions
Last Updated: 27 February 2023
Given a tree with N node and N-1 edges and an array arr[] where arr[i] denotes the value ofith node, the task is to find a set of nodes such that the sum of values is mini...
read more
Tree
Dynamic Programming
Technical Scripter
Technical Scripter 2022
DSA
Memoization
Count distinct original Strings
Last Updated: 28 October 2023
Given a string str. A faulty machine prints bb instead of character a and prints dd instead of char c and for the rest characters it prints normally, the task is to find h...
read more
Dynamic Programming
Recursion
DSA
Algorithms-Dynamic Programming
Algorithms-Recursion
Memoization
recursive-approach
Frog Jump - Climbing Stairs with Cost
Last Updated: 11 November 2024
Given an integer array height[] where height[i] represents the height of the i-th stair, a frog starts from the first stair and wants to reach the top. From any stair i, t...
read more
Dynamic Programming
DSA
Amazon
Adobe
Google
Data Structures
Algorithms-Dynamic Programming
Algorithms-Recursion
Memoization
Count valid strings that contains '0', '1' or '2'
Last Updated: 04 March 2024
Given an integer n(1 = n = 105), the task is to count valid string S of length n, which contains characters '0', '1', or '2' only. For a valid string, it must follow the b...
read more
Dynamic Programming
DSA
Memoization
recursive-approach
Geeks Premier League 2023
Count Ways to Distribute N Chocolates among K persons
Last Updated: 26 March 2024
Given N Chocolates, distribute them among K Persons. We are also given an array of maxChocolates[] of size K. The Chocolates can be distributed in such a manner that the i...
read more
Dynamic Programming
DSA
Algorithms-Dynamic Programming
Memoization
Geeks Premier League 2023
Make Longest Common Subsequence at least K
Last Updated: 10 January 2024
Given two strings A of length N and B of length M. These strings contain lowercase English alphabets. You are also given an integer K. You can change the character of x of...
read more
Dynamic Programming
Geeks Premier League
DSA
Algorithms-Dynamic Programming
Memoization
Geeks Premier League 2023
Reduce N to 1 by given operations
Last Updated: 18 January 2024
Given an integer N. Then your task is to output a minimum number of operations to reduce N into 1. You can below operations to do the same:Subtract 1 from NUpdate N to N/2...
read more
Dynamic Programming
Geeks Premier League
DSA
Algorithms-Dynamic Programming
Memoization
Geeks Premier League 2023
1
2
3
4
We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our
Cookie Policy
&
Privacy Policy
Got It !