Design And Analysis Of Algorithms Set 12

On This Page

This set of Design and Analysis of Algorithms Multiple Choice Questions & Answers (MCQs) focuses on Design And Analysis Of Algorithms Set 12

Q1 | The dynamic programming implementation of the maximum sum rectangle problem uses which of the following algorithm?
Q2 | Given an array, check if the array can be divided into two subsets such that the sum of elements of the two subsets is equal. This is the balanced partition problem. Which of the following methods can be used to solve the balanced partition problem?
Q3 | In which of the following cases, it is not possible to have two subsets with equal sum?
Q4 | What is the time complexity of the brute force algorithm used to solve the balanced partition problem?
Q5 | What is the sum of each of the balanced partitions for the array {5, 6, 7, 10, 3, 1}?
Q6 | You are given n dice each having f faces. You have to find the number of ways in which a sum of S can be achieved. This is the dice throw problem. Which of the following methods can be used to solve the dice throw problem?
Q7 | You have n dice each having f faces. What is the number of permutations that can be obtained when you roll the n dice together?
Q8 | You have 3 dice each having 6 faces. What is the number of permutations that can be obtained when you roll the 3 dice together?
Q9 | You have 2 dice each of them having 6 faces numbered from 1 to 6. What is the number of ways in which a sum of 11 can be achieved?
Q10 | There are n dice with f faces. The faces are numbered from 1 to f. What is the minimum possible sum that can be obtained when the n dice are rolled together?
Q11 | There are n dice with f faces. The faces are numbered from 1 to f. What is the maximum possible sum that can be obtained when the n dice are rolled together?
Q12 | There are 10 dice having 5 faces. The faces are numbered from 1 to 5. What is the number of ways in which a sum of 4 can be achieved?
Q13 | Consider the expression T & F ∧ T. What is the number of ways in which the expression can be parenthesized so that the output is T (true)?
Q14 | Which of the following gives the total number of ways of parenthesizing an expression with n + 1 terms?
Q15 | What is the maximum number of ways in which a boolean expression with n + 1 terms can be parenthesized, such that the output is true?
Q16 | Prim’s algorithm resembles Dijkstra’s algorithm.
Q17 | Which of the following is false about Prim’s algorithm?
Q18 | Which of the following edges form minimum spanning tree on the graph using kruskals algorithm?
Q19 | Which of the following is true?
Q20 | Consider the graph shown below. Which of the following are the edges in the MST of the given graph?
Q21 | Fractional knapsack problem is also known as                      
Q22 | Fractional knapsack problem is solved most efficiently by which of the following algorithm?
Q23 | What is the objective of the knapsack problem?
Q24 | Which of the following statement about 0/1 knapsack and fractional knapsack problem is correct?
Q25 | Time complexity of fractional knapsack problem is