PYQBOOK

Filter Questions

Found 180 question(s)

Q1 MCQ GATE CS Easy 1 Mark 2024
ALGO → Algorithm Analysis
Given an array of N integers, we want to check if the array is sorted (in either order). An algorithm solves this problem by making a single pass through the array and comparing each element of the array only with its adjacent elements. The worst-case time complexity of this algorithm is
Choose One:
Q2 MCQ GATE CS Medium 2 Marks 2024
ALGO → Heaps
An array [82, 101, 90, 11, 111, 75, 33, 131, 44, 93] is heapified. Which one of the following options represents the first three elements in the heapified array?
Choose One:
Q3 MCQ GATE CS Hard 2 Marks 2024
ALGO → Recurrence Relations
Consider the following recurrence relation: T(n) = sqrt(n) * T(sqrt(n)) + n for n >= 1; 1 for n = 1. Which one of the following options is CORRECT?
Choose One:
Q4 NAT GATE CS Easy 2 Marks 2024
ALGO → Graph Traversal
The number of edges present in the forest generated by the DFS traversal of an undirected graph G with 100 vertices is 40. The number of connected components in G is
Enter Numerical Answer:
Q5 MSQ GATE CS Easy 1 Mark 2024
ALGO → Asymptotic Notations
Let f and g be functions of natural numbers given by f(n) = n and g(n) = n^2. Which of the following statements is/are TRUE?
Choose All Applicable: