Engineering & Science
GATE Computer Science
GATE Computer Science Dynamic programming practice questions and solutions
7 questions on Dynamic programming, part of Algorithm Design in the GATE CS Algorithms syllabus. Every question has a worked solution and an explanation of why each wrong option fails. Open a question to attempt it and see the answer.
- Questions
- 7 questions
- Easy
- 2 easy
- Medium
- 4 medium
- Hard
- 1 hard
Questions
- 1What is the length of the longest common subsequence (LCS) of "ABCBDAB" and "BDCABA"?Medium
- 2What is the length of the longest common subsequence of X = ABCBDAB and Y = BDCABA?Hard
- 3The standard dynamic-programming solution to 0/1 knapsack with n items and capacity W runs inEasy
- 4In how many distinct ways can you climb a staircase of 10 steps if each move climbs either 1 or 2 steps?Easy
- 5Matrices A (10 × 20), B (20 × 30) and C (30 × 40) are to be multiplied as ABC. What is the minimum number of…Medium
- 6What is the edit distance between "kitten" and "sitting", if insertion, deletion and substitution each cost 1?Medium
- 7How many structurally different binary search trees can be built with 4 distinct keys?Medium
Practise all GATE CS Algorithms questions with filters