ExamVeda
Login
Home
81
What is the following expression, lcm (a, gcd (a, b)) equal to?
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
82
What will be time complexity when binary search is applied on a linked list?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
83
Which happens if the fast-moving pointer(hare) reaches the tail of the linked list?
Discuss
Answer & Solution
Answer: Option D
No explanation is given for this question. Let's Discuss on Board
84
In a bipartite graph G=(V,U,E), the matching of a free vertex in V to a free vertex in U is called?
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
85
Morse Code is named after which scientist?
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
86
Which one of the following is not an application of max-flow min-cut algorithm?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
87
What is the worst case time complexity of dynamic programming solution of set partition problem(sum=sum of set elements)?
Discuss
Answer & Solution
Answer: Option D
No explanation is given for this question. Let's Discuss on Board
88
Which of the following refers to the minimum number of colors, with which the edges of the graph can be colored?
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
89
Is Coppersmith-Winograd algorithm better than Strassen's algorithm in terms of time complexity?
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
90
What will be the output for the following code?
#include <stdio.h> 
bool func(int arr[], int n, int sum) 
{ 
	bool subarr[n+1][sum+1]; 
	for (int i = 0; i <= n; i++) 
	subarr[i][0] = true; 
	for (int i = 1; i <= sum; i++) 
	subarr[0][i] = false; 
	for (int i = 1; i <= n; i++) 
	{ 
	    for (int j = 1; j <= sum; j++) 
	    { 
		if(j<arr[i-1]) 
		subarr[i][j] = subarr[i-1][j]; 
		if (j >= arr[i-1]) 
		subarr[i][j] = subarr[i-1][j] || 
		subarr[i - 1][j-arr[i-1]]; 
	    } 
	} 
	return subarr[n][sum]; 
} 
 
int main() 
{ 
    int arr[] = {3, 3, 4, 4, 7}; 
    int sum = 5; 
    int n = sizeof(arr)/sizeof(arr[0]); 
    if (func(arr, n, sum) == true) 
	printf("true"); 
    else
	printf("false"); 
    return 0; 
}
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board