Organised by IIT Roorkee

GATE 2025 DA (Data Science & AI) question paper with solutions

65 questions with the official answer key and a worked solution for each. Try a question before opening its answer.

Practise this paper with instant checking
Q1MCQ1 mark · -1/3· Easy

Courage : Bravery :: Yearning : __________ Select the most appropriate option to complete the analogy.

  1. (A)Longing
  2. (B)Yelling
  3. (C)Yawning
  4. (D)Glaring
Answer: A - show solution

Courage and bravery are synonyms, so the second word of the pair must be a synonym of yearning. Yearning means a strong desire for something, which is exactly what longing means. Yelling (shouting), yawning (opening the mouth when tired) and glaring (staring angrily) only resemble yearning in sound or spelling. Answer: (A) Longing.

Concept: Synonym analogy. The trap is the distractors that start with Y or share letters with yearning; match the meaning relation, not the look of the word.

Q2MCQ1 mark · -1/3· Easy

We __________ tennis in the lawn when it suddenly started to rain. Select the most appropriate option to complete the above sentence.

  1. (A)have been playing
  2. (B)had been playing
  3. (C)would have been playing
  4. (D)could be playing
Answer: B - show solution

The interrupting event (it started to rain) is in the simple past. An action that was already in progress before and up to a past event takes the past perfect continuous: had been playing. 'Have been playing' is present perfect continuous and clashes with the past-tense clause; the modal forms change the meaning to something hypothetical. Answer: (B) had been playing.

Concept: Tests the past perfect continuous for an ongoing action interrupted by a past event. The usual trap is picking the present perfect continuous, which cannot pair with a past-tense time clause.

Q3MCQ1 mark · -1/3· Easy

A 4 × 4 digital image has pixel intensities (U) as shown below. The number of pixels with U ≤ 4 is: 0 1 0 2 4 7 3 3 5 5 4 4 6 7 3 2

  1. (A)3
  2. (B)8
  3. (C)11
  4. (D)9
Answer: C - show solution

Count the entries that are at most 4, row by row. Row 1 (0, 1, 0, 2): all 4 qualify. Row 2 (4, 7, 3, 3): 4, 3, 3 qualify - 3 pixels. Row 3 (5, 5, 4, 4): the two 4s - 2 pixels. Row 4 (6, 7, 3, 2): 3 and 2 - 2 pixels. Total = 4 + 3 + 2 + 2 = 11. Answer: (C) 11.

Concept: Simple table reading with an inclusive inequality. The trap is treating ≤ 4 as < 4, which drops the four 4s and gives 7, or miscounting a row.

Q4MCQ1 mark · -1/3· Easy

In a figure, a rectangle, a triangle and an ellipse overlap. The numbers associated with the rectangle, triangle, and ellipse are 1, 2, and 3, respectively; each region of the figure is labelled. The region inside only the rectangle is labelled 1, the region inside only the triangle is labelled 2, the region inside only the ellipse is labelled 3, and the region inside the rectangle and the ellipse but outside the triangle is labelled 4. The region inside all three shapes is labelled P, the region inside the triangle and the ellipse but outside the rectangle is labelled Q, and the region inside the rectangle and the triangle but outside the ellipse is labelled R. Which one among the given options is the most appropriate combination of P, Q, and R?

  1. (A)P = 6; Q = 5; R = 3
  2. (B)P = 5; Q = 6; R = 3
  3. (C)P = 3; Q = 6; R = 6
  4. (D)P = 5; Q = 3; R = 6
Answer: A - show solution

The labelled region 4 lies in the rectangle (1) and the ellipse (3): 1 + 3 = 4, so a region's number is the sum of the numbers of the shapes containing it. P is in all three: 1 + 2 + 3 = 6. Q is in the triangle and the ellipse: 2 + 3 = 5. R is in the rectangle and the triangle: 1 + 2 = 3. Answer: (A) P = 6; Q = 5; R = 3.

Concept: Pattern induction from the one labelled overlap region. The trap is guessing a product or a count rule; check the rule against the given overlap (4 = 1 + 3) before applying it.

Q5MCQ1 mark · -1/3· Easy

A rectangle has a length L and a width W, where L > W. If the width, W, is increased by 10%, which one of the following statements is correct for all values of L and W?

  1. (A)Perimeter increases by 10%.
  2. (B)Length of the diagonals increases by 10%.
  3. (C)Area increases by 10%.
  4. (D)The rectangle becomes a square.
Answer: C - show solution

New width = 1.1W, length unchanged. Area: L × 1.1W = 1.1LW, a 10% increase for every L and W. Perimeter: 2(L + 1.1W) = 2(L + W) + 0.2W, an increase of 0.2W/(2(L + W)), less than 10%. Diagonal: √(L² + 1.21W²) grows by less than 10% because L is unchanged. Square: only if 1.1W = L, which is not true in general. Answer: (C) Area increases by 10%.

Concept: Area is linear in each side, so scaling one side scales area by the same factor; perimeter and diagonal are not. The trap is assuming every measure scales by 10%.

Q6MCQ2 marks · -2/3· Moderate

Column-I has statements made by Shanthala; and, Column-II has responses given by Kanishk. Column-I P. This house is in a mess. Q. I am not happy with the marks given to me. R. Politics is a subject I avoid talking about. S. I don't know what this word means. Column-II 1. Alright, I won't bring it up during our conversations. 2. Well, you can easily look it up. 3. No problem, let me clear it up for you. 4. Don't worry, I will take it up with your teacher. Identify the option that has the correct match between Column-I and Column-II.

  1. (A)P - 2; Q - 3; R - 1; S - 4
  2. (B)P - 3; Q - 4; R - 1; S - 2
  3. (C)P - 4; Q - 1; R - 2; S - 3
  4. (D)P - 1; Q - 2; R - 4; S - 3
Answer: B - show solution

Match each phrasal verb to its meaning. P (a messy house) - 'clear it up' means tidy it: P-3. Q (unhappy with marks) - 'take it up with your teacher' means raise the matter with someone in authority: Q-4. R (avoids politics) - 'won't bring it up' means won't mention the topic: R-1. S (doesn't know a word) - 'look it up' means find it in a dictionary: S-2. Answer: (B) P - 3; Q - 4; R - 1; S - 2.

Concept: Tests phrasal verbs with 'up': clear up, take up, bring up, look up. The trap is that 'clear it up' can also mean explain, which tempts matching it to S; only 'look it up' fits the dictionary sense.

Q7MCQ2 marks · -2/3· Moderate

Weight of a person can be expressed as a function of their age. The function usually varies from person to person. Suppose this function is identical for two brothers, and it monotonically increases till the age of 50 years and then it monotonically decreases. Let a₁ and a₂ (in years) denote the ages of the brothers and a₁ < a₂. Which one of the following statements is correct about their age on the day when they attain the same weight?

  1. (A)a₁ < a₂ < 50
  2. (B)a₁ < 50 < a₂
  3. (C)50 < a₁ < a₂
  4. (D)Either a₁ = 50 or a₂ = 50
Answer: B - show solution

Both brothers follow the same weight function w(a), with a₁ ≠ a₂ and w(a₁) = w(a₂). If both ages were at most 50, w would be strictly increasing there, so a₁ < a₂ would force w(a₁) < w(a₂). If both were at least 50, w would be strictly decreasing, giving w(a₁) > w(a₂). Either way the weights could not be equal. So the two ages must lie on opposite sides of the peak, and neither can be exactly 50 (the peak value is attained only once). Hence a₁ < 50 < a₂. Answer: (B).

Concept: A strictly monotone function is one-to-one, so equal values at different inputs require the inputs to straddle the turning point. The trap is option (D), thinking the peak must be involved.

Q8MCQ2 marks · -2/3· Moderate

A regular dodecagon (12-sided regular polygon) is inscribed in a circle of radius r cm. The side of the dodecagon is d cm. Joining the centre to all 12 vertices divides the dodecagon into 12 triangles (numbered 1 to 12). All these triangles are used to form squares of side r cm and each numbered triangle is used only once to form a square. The number of squares that can be formed and the number of triangles required to form each square, respectively, are:

  1. (A)3; 4
  2. (B)4; 3
  3. (C)3; 3
  4. (D)3; 2
Answer: A - show solution

Each triangle has two sides equal to r with an included angle of 360°/12 = 30°. Area of one triangle = (1/2) r² sin 30° = r²/4. Area of a square of side r = r², so each square needs r² / (r²/4) = 4 triangles. With 12 triangles, the number of squares = 12/4 = 3. Answer: (A) 3; 4.

Concept: Area bookkeeping with the triangle area formula (1/2)ab sin C. The trap is using the side d in the area, or dividing 12 by 3 because a dodecagon suggests multiples of 3.

Q9MCQ2 marks · -2/3· Moderate

If a real variable x satisfies 3^(x²) = 27 × 9^x, then the value of 2^(x²) / (2^x)² is:

  1. (A)2⁻¹
  2. (B)2⁰
  3. (C)2³
  4. (D)2¹⁵
Answer: C - show solution

Write everything in base 3: 3^(x²) = 3³ × 3^(2x) = 3^(3 + 2x), so x² = 2x + 3, i.e. x² - 2x = 3 (x = 3 or x = -1). The required value is 2^(x²) / 2^(2x) = 2^(x² - 2x) = 2³ for either root. Answer: (C) 2³.

Concept: Equate exponents after a common base, then notice the target only needs x² - 2x, not x itself. The trap is reading (2^x)² as 2^(x²), or solving for x and plugging in only one root.

Q10MCQ2 marks · -2/3· Easy

The number of patients per shift (X) consulting Dr. Gita in her past 100 shifts is shown in the bar chart below. If the amount she earns is ₹ 1000(X - 0.2), what is the average amount (in ₹) she has earned per shift in the past 100 shifts? Patients per shift (X): 5 6 7 8 Number of shifts: 20 40 30 10

  1. (A)6,100
  2. (B)6,300
  3. (C)6,000
  4. (D)6,500
Answer: A - show solution

Average X = (5×20 + 6×40 + 7×30 + 8×10)/100 = (100 + 240 + 210 + 80)/100 = 6.3. Earnings are linear in X, so average earnings = 1000(6.3 - 0.2) = ₹ 6,100. Answer: (A) 6,100.

Concept: Weighted mean from a frequency chart and linearity of the mean. The trap is forgetting to subtract 0.2 (giving 6,300) or averaging the four X values without weights.

Q11MCQ1 mark · -1/3· Easy

Suppose X and Y are random variables. The conditional expectation of X given Y is denoted by E[X|Y]. Then E[E[X|Y]] equals

  1. (A)E[X|Y]
  2. (B)E[X] / E[Y]
  3. (C)E[X]
  4. (D)E[Y]
Answer: C - show solution

E[X|Y] is a function of Y. Taking its expectation over Y (discrete case): E[E[X|Y]] = Σ_y E[X|Y=y] P(Y=y) = Σ_y Σ_x x P(X=x|Y=y) P(Y=y) = Σ_x x Σ_y P(X=x, Y=y) = Σ_x x P(X=x) = E[X]. This is the law of total expectation (tower property). Answer: (C) E[X].

Concept: Law of iterated expectations. The trap is treating E[X|Y] as a number (option A) rather than a random variable that still has to be averaged over Y.

Q12MCQ1 mark · -1/3· Easy

The number of additions and multiplications involved in performing Gaussian elimination on any n × n upper triangular matrix is of the order

  1. (A)O(n)
  2. (B)O(n²)
  3. (C)O(n³)
  4. (D)O(n⁴)
Answer: B - show solution

The matrix is already upper triangular, so the forward-elimination stage (the O(n³) part) has nothing to do. What remains is back substitution: x_n needs 1 division, x_(n-1) needs about 2 operations, ..., x_1 needs about n operations. Total ≈ 1 + 2 + ... + n = n(n + 1)/2 multiplications and a similar number of additions, i.e. O(n²). Answer: (B) O(n²).

Concept: Separates the cost of forward elimination (O(n³) for a dense matrix) from back substitution (O(n²)). The trap is quoting the general O(n³) cost without noticing the matrix is already triangular.

Q13MCQ1 mark · -1/3· Moderate

The sum of the elements in each row of A ∈ ℝⁿˣⁿ is 1. If B = A³ - 2A² + A, which one of the following statements is correct (for x ∈ ℝⁿ)?

  1. (A)The equation Bx = 0 has no solution
  2. (B)The equation Bx = 0 has exactly two solutions
  3. (C)The equation Bx = 0 has infinitely many solutions
  4. (D)The equation Bx = 0 has a unique solution
Answer: C - show solution

Let e be the all-ones vector. Row sums equal 1 means Ae = e, so A²e = e and A³e = e. Then Be = e - 2e + e = 0 with e ≠ 0, so B has a non-trivial null space and is singular. A homogeneous system Bx = 0 always has x = 0; once it has one non-zero solution e, every multiple ce is also a solution, so there are infinitely many. Answer: (C).

Concept: Row-sum 1 means 1 is an eigenvalue with eigenvector of all ones; B = A(A - I)² kills that vector. Homogeneous systems are never 'no solution' and never have exactly two solutions.

Q14MCQ1 mark · -1/3· Easy

Let f(x) = (eˣ - e⁻ˣ)/2, x ∈ ℝ. Let f⁽ᵏ⁾(a) denote the kth derivative of f evaluated at a. What is the value of f⁽¹⁰⁾(0)? (Note: ! denotes factorial)

  1. (A)0
  2. (B)1
  3. (C)1/10!
  4. (D)2/10!
Answer: A - show solution

f(x) = sinh x. Differentiating: f' = cosh x, f'' = sinh x, so derivatives alternate between cosh and sinh. Every even-order derivative equals sinh x, so f⁽¹⁰⁾(x) = sinh x and f⁽¹⁰⁾(0) = 0. Equivalently, sinh x = x + x³/3! + x⁵/5! + ... has only odd powers, so the x¹⁰ coefficient f⁽¹⁰⁾(0)/10! is 0. Answer: (A) 0.

Concept: sinh is odd, so its Taylor series at 0 has only odd powers and all even derivatives vanish at 0. The trap is confusing the derivative with the Taylor coefficient f⁽ᵏ⁾(0)/k!, which suggests the 1/10! options.

Q15MCQ1 mark · -1/3· Easy

Let p and q be any two propositions. Consider the following propositional statements. S1 : p → q, S2 : ¬p ∧ q, S3 : ¬p ∨ q, S4 : ¬p ∨ ¬q, where ∧ denotes conjunction (AND operation), ∨ denotes disjunction (OR operation), and ¬ denotes negation (NOT operation). Which one of the following options is correct? (Note: ≡ denotes logical equivalence)

  1. (A)S1 ≡ S3
  2. (B)S2 ≡ S3
  3. (C)S2 ≡ S4
  4. (D)S1 ≡ S4
Answer: A - show solution

p → q is false only when p is true and q is false, which is exactly when ¬p ∨ q is false. So S1 ≡ S3. Check the others: S2 (¬p ∧ q) is false at p = F, q = F while S3 is true; S4 (¬p ∨ ¬q) is true at p = T, q = F while S1 is false; S2 is false at p = T, q = F while S4 is true. Answer: (A) S1 ≡ S3.

Concept: Material implication rewrite p → q ≡ ¬p ∨ q. The trap is mixing up ∧ and ∨, or confusing ¬p ∨ ¬q, which is ¬(p ∧ q), with the implication.

Q16MCQ1 mark · -1/3· Easy

If a relational decomposition is not dependency-preserving, which one of the following relational operators will be executed more frequently in order to maintain the dependencies?

  1. (A)Selection
  2. (B)Projection
  3. (C)Join
  4. (D)Set union
Answer: C - show solution

In a dependency-preserving decomposition, every functional dependency can be checked inside a single decomposed relation. If it is not preserved, some dependency X → Y spans attributes held in different relations, so to check it on every update the relations must be recombined - that is, joined - before the dependency can be verified. Hence joins are executed more often. Answer: (C) Join.

Concept: Dependency preservation means FDs can be enforced locally. The trap is choosing projection because decomposition itself is a projection; the extra cost of enforcement comes from rejoining.

Q17MCQ1 mark · -1/3· Easy

Consider the following three relations: Car (model, year, serial, color) Make (maker, model) Own (owner, serial) A tuple in Car represents a specific car of a given model, made in a given year, with a serial number and a color. A tuple in Make specifies that a maker company makes cars of a certain model. A tuple in Own specifies that an owner owns the car with a given serial number. Keys are underlined; (owner, serial) together form key for Own. (⋈ denotes natural join) π_owner(Own ⋈ (σ_color="red"(Car ⋈ (σ_maker="ABC" Make)))) Which one of the following options describes what the above expression computes?

  1. (A)All owners of a red car, a car made by ABC, or a red car made by ABC
  2. (B)All owners of more than one car, where at least one car is red and made by ABC
  3. (C)All owners of a red car made by ABC
  4. (D)All red cars made by ABC
Answer: C - show solution

Inside out: σ_maker="ABC"(Make) gives the models made by ABC. Joining with Car on model gives the cars of those models. σ_color="red" keeps only red ones, so we have red cars made by ABC. Joining with Own on serial attaches the owners of those cars, and π_owner returns the owners. Answer: (C) All owners of a red car made by ABC.

Concept: Reading nested selections and natural joins: selections are conjunctive (red AND ABC), not a union. Option (D) forgets the final projection is onto owner, and (B) invents a count condition.

Q18MCQ1 mark · -1/3· Easy

Consider a hash table of size 10 with indices {0, 1, ..., 9}, with the hash function h(x) = 3x (mod 10), where linear probing is used to handle collisions. The hash table is initially empty and then the following sequence of keys is inserted into the hash table: 1, 4, 5, 6, 14, 15. The indices where the keys 14 and 15 are stored are, respectively

  1. (A)2 and 5
  2. (B)2 and 6
  3. (C)4 and 5
  4. (D)4 and 6
Answer: D - show solution

h(1) = 3 -> slot 3. h(4) = 12 mod 10 = 2 -> slot 2. h(5) = 15 mod 10 = 5 -> slot 5. h(6) = 18 mod 10 = 8 -> slot 8. h(14) = 42 mod 10 = 2: slot 2 full, 3 full, 4 free -> slot 4. h(15) = 45 mod 10 = 5: slot 5 full, 6 free -> slot 6. Answer: (D) 4 and 6.

Concept: Linear probing moves to the next free slot on a collision. The trap is reporting the home slot (2 and 5) instead of where the key actually lands after probing.

Q19MCQ1 mark · -1/3· Easy

Let X be a continuous random variable whose cumulative distribution function (CDF) F_X(x), for some t, is given as follows: F_X(x) = 0 for x ≤ t; (x - t)/(4 - t) for t ≤ x ≤ 4; 1 for x ≥ 4. If the median of X is 3, then what is the value of t?

  1. (A)2
  2. (B)1
  3. (C)-1
  4. (D)0
Answer: A - show solution

X is uniform on [t, 4]. The median m satisfies F_X(m) = 1/2: (3 - t)/(4 - t) = 1/2, so 6 - 2t = 4 - t, giving t = 2. Check: the median of uniform[2, 4] is the midpoint 3. Answer: (A) 2.

Concept: Median from a CDF: solve F(m) = 0.5. For a uniform distribution it is the midpoint, so t = 2·3 - 4 directly. The trap is setting F(3) = 3 or using the mean formula incorrectly.

Q20MCQ1 mark · -1/3· Easy

Let X = aZ + b, where Z is a standard normal random variable, and a, b are two unknown constants. It is given that E[X] = 1, E[(X - E[X])Z] = -2, E[(X - E[X])²] = 4, where E[X] denotes the expectation of random variable X. The values of a, b are:

  1. (A)a = -2, b = 1
  2. (B)a = 2, b = -1
  3. (C)a = -2, b = -1
  4. (D)a = 1, b = 1
Answer: A - show solution

E[X] = aE[Z] + b = b, so b = 1. X - E[X] = aZ, so E[(X - E[X])Z] = aE[Z²] = a = -2. Check: E[(X - E[X])²] = a² E[Z²] = 4. Consistent. Answer: (A) a = -2, b = 1.

Concept: Uses E[Z] = 0 and E[Z²] = 1. The variance alone gives a = ±2; the covariance with Z fixes the sign. The trap is stopping at the variance and picking a = 2.

Q21MCQ1 mark · -1/3· Easy

It is given that P(X ≥ 2) = 0.25 for an exponentially distributed random variable X with E[X] = 1/λ, where E[X] denotes the expectation of X. What is the value of λ? (ln denotes natural logarithm)

  1. (A)ln 2
  2. (B)ln 4
  3. (C)ln 3
  4. (D)ln 0.25
Answer: A - show solution

For an exponential with rate λ, P(X ≥ x) = e^(-λx). So e^(-2λ) = 0.25, giving -2λ = ln 0.25 = -ln 4, λ = (ln 4)/2 = ln 2. Answer: (A) ln 2.

Concept: Exponential survival function e^(-λx). The trap is forgetting to divide by 2 (giving ln 4) or dropping the minus sign (ln 0.25, which is negative and not a valid rate).

Q22MCQ1 mark · -1/3· Easy

Consider designing a linear classifier y = sign(f(x; w, b)), f(x; w, b) = wᵀx + b on a dataset D = {(x₁, y₁), (x₂, y₂), ..., (x_N, y_N)}, xᵢ ∈ ℝᵈ, yᵢ ∈ {+1, -1}, i = 1, 2, ..., N. Recall that the sign function outputs +1 if the argument is positive, and -1 if the argument is non-positive. The parameters w and b are updated as per the following training algorithm: w_new = w_old + y_n x_n, b_new = b_old + y_n whenever sign(f(x_n; w_old, b_old)) ≠ y_n. In other words, whenever the classifier wrongly predicts a sample (x_n, y_n) from the dataset, w_old gets updated to w_new, and likewise b_old gets updated to b_new. Consider the case (x_n, +1), f(x_n; w_old, b_old) < 0. Then

  1. (A)f(x_n; w_new, b_new) > f(x_n; w_old, b_old)
  2. (B)f(x_n; w_new, b_new) < f(x_n; w_old, b_old)
  3. (C)f(x_n; w_new, b_new) = f(x_n; w_old, b_old)
  4. (D)y_n f(x_n; w_old, b_old) > 1
Answer: A - show solution

Here y_n = +1 and f < 0, so the sample is misclassified and an update happens: w_new = w_old + x_n, b_new = b_old + 1. f(x_n; w_new, b_new) = (w_old + x_n)ᵀx_n + b_old + 1 = f(x_n; w_old, b_old) + ‖x_n‖² + 1. Since ‖x_n‖² + 1 > 0, the new score is strictly larger. (D) is false because y_n f = f < 0. Answer: (A).

Concept: This is the perceptron update: each mistake pushes the score for that sample toward its correct sign by ‖x‖² + 1. The trap is thinking one update must fix the sign or leave f unchanged.

Q23MCQ1 mark · -1/3· Easy

Consider the following Python declarations of two lists. Which one of the following statements results in A = [1, 2, 3, 4, 5, 6]?

A=[1,2,3]
B=[4,5,6]
  1. (A)A.extend(B)
  2. (B)A.append(B)
  3. (C)A.update(B)
  4. (D)A.insert(B)
Answer: A - show solution

A.extend(B) appends each element of B to A in place, giving [1, 2, 3, 4, 5, 6]. A.append(B) adds B as a single element: [1, 2, 3, [4, 5, 6]]. Lists have no update method (that is for dict and set), so A.update(B) raises AttributeError. A.insert needs an index and a value; A.insert(B) raises TypeError. Answer: (A) A.extend(B).

Concept: List methods: extend concatenates, append nests. The trap is append, which produces a nested list, and update, which exists only on dict/set.

Q24MSQ1 mark · no negative· Moderate

Consider two functions f : ℝ → ℝ and g : ℝ → (1, ∞). Both functions are differentiable at a point c. Which of the following functions is/are ALWAYS differentiable at c? The symbol · denotes product and the symbol ∘ denotes composition of functions.

  1. (A)f ± g
  2. (B)f · g
  3. (C)f / g
  4. (D)f ∘ g + g ∘ f
Answer: A, B, C - show solution

Sum, difference and product of functions differentiable at c are differentiable at c. f/g: g > 1 so g(c) ≠ 0, and the quotient rule applies - differentiable. f ∘ g needs f differentiable at g(c), and g ∘ f needs g differentiable at f(c); we only know differentiability at c. Example: c = 0, g(x) = 2 + eˣ (always > 1), f(x) = |x - 3|; f is differentiable at 0, but f(g(x)) = |eˣ - 1| has a corner at 0, while g(f(x)) = 2 + e^|x - 3| is differentiable at 0, so the sum is not differentiable at 0. Answer: (A), (B), (C).

Concept: Algebraic combinations preserve differentiability at a point (quotient needs a non-zero denominator, guaranteed by g > 1). Composition needs differentiability at the image point, which is not given.

Q25MSQ1 mark · no negative· Easy

Which of the following statements is/are correct?

  1. (A)ℝⁿ has a unique set of orthonormal basis vectors
  2. (B)ℝⁿ does not have a unique set of orthonormal basis vectors
  3. (C)Linearly independent vectors in ℝⁿ are orthonormal
  4. (D)Orthonormal vectors in ℝⁿ are linearly independent
Answer: B, D - show solution

Any rotation of the standard basis is another orthonormal basis (e.g. in ℝ², (1/√2)(1, 1) and (1/√2)(1, -1)), so the orthonormal basis is not unique: (A) false, (B) true. (C) false: (1, 0) and (1, 1) are independent but not orthogonal. (D) true: if Σ cᵢvᵢ = 0, taking the dot product with v_j gives c_j = 0 for every j. Answer: (B), (D).

Concept: Orthonormal implies independent, not the converse; orthonormal bases are unique only up to an orthogonal transformation. Note for n = 1 there are still two (±1).

Q26MSQ1 mark · no negative· Easy

Which of the following statements is/are correct in a Bayesian network?

  1. (A)Variable elimination is an approximate inference algorithm
  2. (B)Gibbs sampling is an exact inference algorithm
  3. (C)Variable elimination is used to determine conditional probabilities
  4. (D)Rejection sampling is an approximate inference algorithm
Answer: C, D - show solution

Variable elimination sums out hidden variables factor by factor and returns the exact posterior P(query | evidence), so it is an exact algorithm used to compute conditional probabilities: (A) false, (C) true. Gibbs sampling and rejection sampling estimate probabilities from samples; the estimates converge only as the number of samples grows, so both are approximate: (B) false, (D) true. Answer: (C), (D).

Concept: Exact inference (enumeration, variable elimination) versus approximate inference (rejection sampling, likelihood weighting, Gibbs/MCMC). The trap is swapping the categories.

Q27MSQ1 mark · no negative· Easy

For which of the following inputs does binary search take time O(log n) in the worst case?

  1. (A)An array of n integers in any order
  2. (B)A linked list of n integers in any order
  3. (C)An array of n integers in increasing order
  4. (D)A linked list of n integers in increasing order
Answer: C - show solution

Binary search needs sorted data (otherwise discarding half the range is unjustified) and O(1) access to the middle element. An unsorted array or list fails the first requirement. A sorted linked list fails the second: reaching the middle takes O(n) steps, so the total is O(n). Only a sorted array gives O(log n). Answer: (C).

Concept: Binary search requires both order and random access. The trap is the sorted linked list: it has order but no random access, so it degrades to linear time.

Q28MSQ1 mark · no negative· Moderate

Let A = Iₙ + xxᵀ, where Iₙ is the n × n identity matrix and x ∈ ℝⁿ, xᵀx = 1. Which of the following options is/are correct?

  1. (A)Rank of A is n
  2. (B)A is invertible
  3. (C)0 is an eigenvalue of A
  4. (D)A⁻¹ has a negative eigenvalue
Answer: A, B - show solution

Ax = x + x(xᵀx) = 2x, so 2 is an eigenvalue. For any v ⊥ x, Av = v, giving eigenvalue 1 with multiplicity n - 1. All eigenvalues (2, 1, ..., 1) are non-zero, so A is invertible with rank n: (A), (B) true; (C) false. A⁻¹ has eigenvalues 1/2 and 1, all positive: (D) false. Answer: (A), (B).

Concept: A rank-one update of the identity: eigenvalues are 1 + xᵀx along x and 1 elsewhere. The trap is confusing it with I - xxᵀ, a projection that does have eigenvalue 0.

Q29MSQ1 mark · no negative· Moderate

Suppose that insertion sort is applied to the array [1, 3, 5, 7, 9, 11, x, 15, 13] and it takes exactly two swaps to sort the array. Select all possible values of x.

  1. (A)10
  2. (B)12
  3. (C)14
  4. (D)16
Answer: A, C - show solution

Insertion sort makes one adjacent swap per inversion. The pair (15, 13) is always one inversion, so x must create exactly one more. x = 10: 11 > 10 before it - 1 inversion; 10 < 15, 13. Total 2. Yes. x = 12: nothing before it is larger, and 12 < 15, 13. Total 1. No. x = 14: 14 > 13 after it - 1 inversion. Total 2. Yes. x = 16: 16 > 15 and 16 > 13 - 2 inversions. Total 3. No. Answer: (A) 10, (C) 14.

Concept: Swaps in insertion sort equal the number of inversions. The trap is counting only inversions involving x and forgetting the fixed (15, 13) pair.

Q30MSQ1 mark · no negative· Easy

Let C₁ and C₂ be two sets of objects. Let D(x, y) be a measure of dissimilarity between two objects x and y. Consider the following definitions of dissimilarity between C₁ and C₂. DIS-1(C₁, C₂) = max over x ∈ C₁, y ∈ C₂ of D(x, y) DIS-2(C₁, C₂) = min over x ∈ C₁, y ∈ C₂ of D(x, y) Which of the following statements is/are correct?

  1. (A)Single Linkage Clustering uses DIS-1
  2. (B)Single Linkage Clustering uses DIS-2
  3. (C)Complete Linkage Clustering uses DIS-2
  4. (D)Complete Linkage Clustering uses DIS-1
Answer: B, D - show solution

Single linkage measures the distance between two clusters by their closest pair of points - the minimum, DIS-2. Complete linkage uses their farthest pair - the maximum, DIS-1. Answer: (B), (D).

Concept: Linkage criteria in hierarchical clustering: single = nearest neighbour (min), complete = farthest neighbour (max), average = mean. The trap is associating 'complete' with 'closest'.

Q31NAT1 mark · no negative· Easy

There are three boxes containing white balls and black balls. Box-1 contains 2 black and 1 white balls. Box-2 contains 1 black and 2 white balls. Box-3 contains 3 black and 3 white balls. In a random experiment, one of these boxes is selected, where the probability of choosing Box-1 is 1/2, Box-2 is 1/6, and Box-3 is 1/3. A ball is drawn at random from the selected box. Given that the ball drawn is white, the probability that it is drawn from Box-2 is ______ (Round off to two decimal places)

Answer: 0.25 - show solution

P(W) = (1/2)(1/3) + (1/6)(2/3) + (1/3)(3/6) = 1/6 + 1/9 + 1/6 = 3/18 + 2/18 + 3/18 = 8/18. P(Box-2 and W) = (1/6)(2/3) = 2/18. P(Box-2 | W) = (2/18)/(8/18) = 1/4 = 0.25. Answer: 0.25.

Concept: Bayes' theorem with the law of total probability in the denominator. The trap is ignoring the unequal box priors and using 2/3 or the plain fraction of white balls.

Q32NAT1 mark · no negative· Easy

lim (t → +∞) of (√(t² + t) - t) = ______ (Round off to one decimal place)

Answer: 0.5 - show solution

Multiply by the conjugate: √(t² + t) - t = (t² + t - t²)/(√(t² + t) + t) = t/(√(t² + t) + t) = 1/(√(1 + 1/t) + 1). As t → ∞ this tends to 1/(1 + 1) = 0.5. Answer: 0.5.

Concept: An ∞ - ∞ form resolved by rationalising. The trap is concluding the limit is 0 because √(t² + t) 'is about t'.

Q33NAT1 mark · no negative· Easy

On a relation named Loan of a bank: Loan loan_number branch_name amount L11 Banjara Hills 90000 L14 Kondapur 50000 L15 SR Nagar 40000 L22 SR Nagar 25000 L23 Balanagar 80000 L25 Kondapur 70000 L19 SR Nagar 65000 the following SQL query is executed. The number of rows returned by the query is ______ (Answer in integer)

SELECT L1.loan_number
FROM Loan L1
WHERE L1.amount > (SELECT MAX (L2.amount)
                   FROM Loan L2
                   WHERE L2.branch_name = 'SR Nagar');
Answer: 3 - show solution

Inner query: SR Nagar loans are 40000, 25000 and 65000, so MAX = 65000. Outer query keeps loans with amount > 65000: L11 (90000), L23 (80000), L25 (70000). L19 itself (65000) is not strictly greater. Rows returned = 3.

Concept: A scalar subquery with MAX, then a strict comparison. The trap is using >= (which would add L19) or comparing against the SR Nagar total instead of the maximum.

Q34NAT1 mark · no negative· Easy

Given data {(-1, 1), (2, -5), (3, 5)} of the form (x, y), we fit a model y = wx using linear least-squares regression. The optimal value of w is ______ (Round off to three decimal places)

Answer: 0.285 to 0.287 - show solution

Minimise Σ(yᵢ - w xᵢ)². Setting the derivative to zero gives w = Σxᵢyᵢ / Σxᵢ². Σxy = (-1)(1) + (2)(-5) + (3)(5) = -1 - 10 + 15 = 4. Σx² = 1 + 4 + 9 = 14. w = 4/14 = 0.2857... ≈ 0.286 (key accepts 0.285 to 0.287).

Concept: Regression through the origin (no intercept): w = Σxy/Σx². The trap is using the intercept formula with means subtracted, which answers a different model.

Q35NAT1 mark · no negative· Easy

The naive Bayes classifier is used to solve a two-class classification problem with class-labels y₁, y₂. Suppose the prior probabilities are P(y₁) = 1/3 and P(y₂) = 2/3. Assuming a discrete feature space with P(x|y₁) = 3/4 and P(x|y₂) = 1/4 for a specific feature vector x. The probability of misclassifying x is ______ (Round off to two decimal places)

Answer: 0.39 to 0.41 - show solution

Joint scores: P(x|y₁)P(y₁) = (3/4)(1/3) = 1/4 and P(x|y₂)P(y₂) = (1/4)(2/3) = 1/6. Since 1/4 > 1/6 the classifier predicts y₁. It is wrong when the true class is y₂: P(y₂|x) = (1/6)/(1/4 + 1/6) = (2/12)/(5/12) = 0.4. Answer: 0.40 (key range 0.39 to 0.41).

Concept: Bayes decision rule picks the larger posterior; the error probability for that x is the smaller posterior. The trap is reporting the unnormalised 1/6 or the prior 2/3.

Q36MCQ2 marks · -2/3· Moderate

Let Y = Z², Z = (X - μ)/σ, where X is a normal random variable with mean μ and variance σ². The variance of Y is

  1. (A)1
  2. (B)2
  3. (C)3
  4. (D)4
Answer: B - show solution

Z is standard normal, so E[Z²] = 1 and E[Z⁴] = 3. Var(Y) = E[Z⁴] - (E[Z²])² = 3 - 1 = 2. (Y is chi-squared with 1 degree of freedom, whose variance is 2k = 2.) Answer: (B) 2.

Concept: The fourth moment of a standard normal is 3. The trap is answering 3 (the fourth moment itself) or 1 (the mean of Y).

Q37MCQ2 marks · -2/3· Moderate

Let A ∈ ℝⁿˣⁿ be such that A³ = A. Which one of the following statements is ALWAYS correct?

  1. (A)A is invertible
  2. (B)Determinant of A is 0
  3. (C)The sum of the diagonal elements of A is 1
  4. (D)A and A² have the same rank
Answer: D - show solution

rank(A) = rank(A³) = rank(A · A²) ≤ rank(A²) = rank(A · A) ≤ rank(A). So rank(A²) = rank(A) always: (D) true. Counterexamples for the rest: A = 0 satisfies A³ = A but is not invertible and has trace 0, killing (A) and (C); A = I satisfies it with determinant 1, killing (B). Answer: (D).

Concept: Rank of a product never exceeds the rank of either factor; sandwiching gives equality. Eigenvalues are in {-1, 0, 1}, so determinant and trace vary. The trap is assuming A must be singular.

Q38MCQ2 marks · -2/3· Moderate

Let {x₁, x₂, ..., xₙ} be a set of linearly independent vectors in ℝⁿ. Let the (i, j)-th element of matrix A ∈ ℝⁿˣⁿ be given by Aᵢⱼ = xᵢᵀxⱼ, 1 ≤ i, j ≤ n. Which one of the following statements is correct?

  1. (A)A is invertible
  2. (B)0 is a singular value of A
  3. (C)Determinant of A is 0
  4. (D)zᵀAz = 0 for some non-zero z ∈ ℝⁿ
Answer: A - show solution

Let X be the matrix with columns x₁, ..., xₙ. Then A = XᵀX (a Gram matrix). For any z, zᵀAz = (Xz)ᵀ(Xz) = ‖Xz‖². Because the columns are independent, Xz ≠ 0 whenever z ≠ 0, so zᵀAz > 0: A is positive definite. A positive definite matrix has all eigenvalues (and singular values) positive, so det A > 0 and A is invertible. (B), (C), (D) are all false. Answer: (A).

Concept: Gram matrix of independent vectors is positive definite. The trap is option (D): zᵀAz = ‖Xz‖² is zero only if Xz = 0, impossible for independent columns.

Q39MCQ2 marks · -2/3· Easy

Consider the cumulative distribution function (CDF) of a random variable X: F_X(x) = 0 for x ≤ -1; (1/4)(x + 1)² for -1 ≤ x ≤ 1; 1 for x ≥ 1. The value of P(X² ≤ 0.25) is

  1. (A)0.625
  2. (B)0.25
  3. (C)0.5
  4. (D)0.5625
Answer: C - show solution

X² ≤ 0.25 means -0.5 ≤ X ≤ 0.5. X is continuous, so P = F(0.5) - F(-0.5) = (1/4)(1.5)² - (1/4)(0.5)² = (2.25 - 0.25)/4 = 0.5. Answer: (C) 0.5.

Concept: Convert the event on X² into an interval on X, then difference the CDF. The trap is computing only F(0.5) = 0.5625 (option D), forgetting the lower end.

Q40MCQ2 marks · -2/3· Moderate

A random variable X is said to be distributed as Bernoulli(θ), denoted by X ∼ Bernoulli(θ), if P(X = 1) = θ, P(X = 0) = 1 - θ for 0 < θ < 1. Let Y = Σ (i = 1 to 300) Xᵢ, where Xᵢ ∼ Bernoulli(θ), i = 1, 2, ..., 300 be independent and identically distributed random variables with θ = 0.25. The value of P(60 ≤ Y ≤ 90), after approximation through Central Limit Theorem, is given by Recall that φ(x) = (1/√(2π)) ∫ from -∞ to x of e^(-t²/2) dt

  1. (A)φ(2) - φ(-2)
  2. (B)φ(1) - φ(-1)
  3. (C)φ(3) - φ(-3)
  4. (D)φ(90) - φ(60)
Answer: A - show solution

E[Y] = 300 × 0.25 = 75, Var(Y) = 300 × 0.25 × 0.75 = 56.25, SD = 7.5. Standardise: (60 - 75)/7.5 = -2 and (90 - 75)/7.5 = 2. P(60 ≤ Y ≤ 90) ≈ φ(2) - φ(-2). Answer: (A).

Concept: CLT approximation of a binomial sum by N(nθ, nθ(1 - θ)); here φ is the standard normal CDF. The trap is plugging raw values into φ (option D) or using the variance instead of the SD.

Q41MCQ2 marks · -2/3· Moderate

For x ∈ ℝ, the floor function is denoted by f(x) = ⌊x⌋ and defined as follows ⌊x⌋ = k, k ≤ x < k + 1, where k is an integer. Let Y = ⌊X⌋, where X is an exponentially distributed random variable with mean 1/(ln 10), where ln denotes natural logarithm. For any positive integer ℓ, one can write the probability of the event Y = ℓ as follows P(Y = ℓ) = q^ℓ (1 - q) The value of q is

  1. (A)0.1
  2. (B)0.01
  3. (C)0.5
  4. (D)0.434
Answer: A - show solution

Mean 1/ln 10 means rate λ = ln 10, so P(X ≥ x) = e^(-x ln 10) = 10^(-x). P(Y = ℓ) = P(ℓ ≤ X < ℓ + 1) = 10^(-ℓ) - 10^(-(ℓ+1)) = (0.1)^ℓ (1 - 0.1). Matching q^ℓ(1 - q) gives q = 0.1. Answer: (A) 0.1.

Concept: The floor of an exponential variable is geometric with q = e^(-λ). The trap is option (D), 0.434 = 1/ln 10, which is the mean, not e^(-λ).

Q42MCQ2 marks · -2/3· Moderate

Consider a neural network with inputs u, v; weights a, b, c, d, e, f; and output y. R denotes the ReLU function, R(x) = max(0, x). The network has two hidden ReLU units and one ReLU output unit: h₁ = R(a·u + b·v), h₂ = R(c·u + d·v), y = R(e·h₁ + f·h₂) (u connects to h₁ with weight a and to h₂ with weight c; v connects to h₁ with weight b and to h₂ with weight d; h₁ and h₂ connect to the output with weights e and f.) Given u = 2, v = 3, a = 1, b = 1, c = 1, d = -1, e = 4, f = -1, which one of the following is correct?

  1. (A)∂y/∂a = 8, ∂y/∂f = 0
  2. (B)∂y/∂a = 1, ∂y/∂f = 0
  3. (C)∂y/∂a = 1, ∂y/∂f = -1
  4. (D)∂y/∂a = 2, ∂y/∂f = -1
Answer: A - show solution

Forward pass: h₁ = R(2 + 3) = 5; h₂ = R(2 - 3) = R(-1) = 0; output pre-activation = 4·5 + (-1)·0 = 20 > 0, so y = 20. The output ReLU is active (derivative 1). ∂y/∂f = 1 · h₂ = 0. ∂y/∂a = 1 · e · R'(5) · u = 4 · 1 · 2 = 8 (h₁'s ReLU is active). Answer: (A) ∂y/∂a = 8, ∂y/∂f = 0.

Concept: Backpropagation through ReLUs: the gradient passes unchanged through active units and is zero through inactive ones. The trap is forgetting the chain factors e and u, or not noticing h₂ is zero so ∂y/∂f vanishes.

Q43MCQ2 marks · -2/3· Moderate

Consider game trees Tree-1 and Tree-2. The first level is a MAX agent and the second level is a MIN agent. Leaf values are outputs of the utility function. Children are explored left to right. Tree-1: root A (MAX) has a left child that is a leaf with value 2 and a right child B (MIN); B has a left leaf x and a right leaf 1. Tree-2: root C (MAX) has children D (MIN) and E (MIN); D has leaves 5 and y; E has a left leaf 2 and a right subtree. For what ranges of x and y, the right child of node B and the right child of node E will be pruned by alpha-beta pruning algorithm?

  1. (A)x ∈ [1, ∞) and y ∈ (-∞, 2]
  2. (B)x ∈ (-∞, 2] and y ∈ (-∞, 5]
  3. (C)x ∈ (-∞, 2] and y ∈ [2, ∞)
  4. (D)x ∈ [1, ∞) and y ∈ (-∞, 5]
Answer: C - show solution

Tree-1: after the left leaf, A has α = 2. At MIN node B, after seeing x, β = x. Prune B's right child when β ≤ α, i.e. x ≤ 2: x ∈ (-∞, 2]. Tree-2: D = min(5, y), so C has α = min(5, y). At E, after the leaf 2, β = 2. Prune when 2 ≤ α = min(5, y), i.e. y ≥ 2 (and 2 ≤ 5 holds): y ∈ [2, ∞). Answer: (C).

Concept: Alpha-beta prunes a MIN node's remaining children once its upper bound β drops to or below the MAX ancestor's lower bound α. The trap is reversing the inequality or using 5 instead of min(5, y) as α.

Q44MCQ2 marks · -2/3· Moderate

A state graph has the following directed edges with action costs: S→A (4), S→E (1), A→B (2), B→C (2), E→C (2), C→D (3), D→G (3). The heuristic values are h(A) = 2, h(B) = 2, h(C) = 6, h(D) = 2, h(E) = 6, h(G) = 0. S is the start and G is the goal. Suppose A* algorithm is applied on this state graph using priority queue to store the frontier. In what sequence are the nodes expanded?

  1. (A)S,A,E,C,B,D,G
  2. (B)S,E,A,C,B,D,G
  3. (C)S,A,E,B,C,D,G
  4. (D)S,A,B,E,C,D,G
Answer: C - show solution

f = g + h. Expand S: A (g 4, f 6), E (g 1, f 7). Expand A (6): B (g 6, f 8). Frontier: E 7, B 8. Expand E (7): C (g 3, f 9). Frontier: B 8, C 9. Expand B (8): C via B has g 8, worse than 3, ignored. Expand C (9): D (g 6, f 8). Expand D (8): G (g 9, f 9). Expand G. Order: S, A, E, B, C, D, G. Answer: (C).

Concept: A* orders by g + h, not by g or h alone. The trap is expanding E first because its edge cost is smallest (that is uniform-cost thinking), or expanding C before B.

Q45MCQ2 marks · -2/3· Easy

A random experiment consists of throwing 100 fair dice, each die having six faces numbered 1 to 6. An event A represents the set of all outcomes where at least one of the dice shows a 1. Then, P(A) =

  1. (A)0
  2. (B)1
  3. (C)1 - (5/6)¹⁰⁰
  4. (D)(5/6)¹⁰⁰
Answer: C - show solution

Complement: no die shows a 1. Each die avoids 1 with probability 5/6, independently, so P(no 1) = (5/6)¹⁰⁰. P(A) = 1 - (5/6)¹⁰⁰. Answer: (C).

Concept: 'At least one' is easiest via the complement 'none'. The trap is option (D), which is the complement itself, or (B), since 100 dice make a 1 very likely but not certain.

Q46MCQ2 marks · -2/3· Moderate

Consider a fact table in an OLAP application: Facts(D1, D2, val), where D1 and D2 are its dimension attributes and val is a dependent attribute. Suppose attribute D1 takes 3 values and D2 takes 2 values, and all combinations of these values are present in the table Facts. How many tuples are there in the result of the following query?

SELECT D1, D2, sum(val)
FROM Facts
GROUP BY CUBE (D1, D2);
  1. (A)1
  2. (B)6
  3. (C)9
  4. (D)12
Answer: D - show solution

CUBE(D1, D2) produces groupings for every subset of {D1, D2}: (D1, D2): 3 × 2 = 6 rows (D1): 3 rows (D2 shown as NULL) (D2): 2 rows (D1 shown as NULL) (): 1 grand-total row Total = 6 + 3 + 2 + 1 = 12. Answer: (D) 12.

Concept: CUBE over k attributes gives all 2ᵏ grouping sets; ROLLUP gives only the k + 1 hierarchical ones (here 10). The trap is counting just the 6 base groups.

Q47MCQ2 marks · -2/3· Moderate

Consider the following Python code snippet. When the above program is executed, at the end, which of the following sets contains "this"?

A={"this","that"}
B={"that","other"}
C={"other","this"}
while "other" in C:
    if "this" in A:
        A,B,C=A-B,B-C,C-A
    if "that" in B:
        A,B,C=C|A,A|B,B|C
  1. (A)Only A
  2. (B)Only B
  3. (C)Only C
  4. (D)A, C
Answer: B - show solution

Tuple assignment evaluates all right-hand sides with the old values first. Iteration 1: "other" in C. "this" in A, so A = A - B = {this}, B = B - C = {that}, C = C - A = {other}. "that" in B, so A = C | A = {other, this}, B = A | B = {this, that}, C = B | C = {that, other}. Iteration 2: "other" in C. "this" in A: A = A - B = {other}, B = B - C = {this}, C = C - A = {that}. "that" is not in B, so no second update. Iteration 3: "other" not in C, loop ends with A = {other}, B = {this}, C = {that}. Answer: (B) Only B.

Concept: Set difference and union with simultaneous tuple assignment. The trap is updating A first and then using the new A when computing B and C.

Q48MSQ2 marks · no negative· Easy

Which of the following statements is/are correct about the rectified linear unit (ReLU) activation function defined as ReLU(x) = max(x, 0), where x ∈ ℝ?

  1. (A)ReLU is continuous everywhere
  2. (B)ReLU is differentiable everywhere
  3. (C)ReLU is not differentiable at x = 0
  4. (D)ReLU(x) = ReLU(ax), for all a ∈ ℝ
Answer: A, C - show solution

ReLU is 0 for x ≤ 0 and x for x ≥ 0; both pieces meet at 0, so it is continuous everywhere: (A) true. At 0 the left derivative is 0 and the right derivative is 1, so it is not differentiable there: (B) false, (C) true. (D) fails, e.g. x = 1, a = 2: ReLU(1) = 1 but ReLU(2) = 2. Answer: (A), (C).

Concept: A corner gives continuity without differentiability. The trap is (D): ReLU is positively homogeneous, ReLU(ax) = a ReLU(x) for a ≥ 0, not invariant to scaling.

Q49MSQ2 marks · no negative· Moderate

Consider the function f(x) = x³/3 + (7/2)x² + 10x + 133/2, x ∈ [-8, 0]. Which of the following statements is/are correct?

  1. (A)The maximum value of f is attained at x = -5
  2. (B)The minimum value of f is attained at x = -2
  3. (C)The maximum value of f is 133/2
  4. (D)The minimum value of the derivative of f is attained at x = -7/2
Answer: C, D - show solution

f'(x) = x² + 7x + 10 = (x + 2)(x + 5); critical points x = -5 (local max, f'' = 2x + 7 = -3 < 0) and x = -2 (local min, f'' = 3 > 0). Values: f(-8) = -512/3 + 224 - 80 + 66.5 ≈ 39.83; f(-5) = -125/3 + 87.5 - 50 + 66.5 ≈ 62.33; f(-2) = -8/3 + 14 - 20 + 66.5 ≈ 57.83; f(0) = 66.5. Global max = 133/2 at x = 0, not at -5: (A) false, (C) true. Global min is at x = -8, not -2: (B) false. f' is a parabola opening upward with vertex at x = -7/2, inside [-8, 0]: (D) true. Answer: (C), (D).

Concept: On a closed interval compare critical points with the endpoints. The trap is equating local extrema with global ones: here both global extrema occur at the endpoints.

Q50MSQ2 marks · no negative· Moderate

Let x₁, x₂, x₃, x₄, x₅ be a system of orthonormal vectors in ℝ¹⁰. Consider the matrix A = x₁x₁ᵀ + ... + x₅x₅ᵀ. Which of the following statements is/are correct?

  1. (A)Singular values of A are also its eigenvalues
  2. (B)Singular values of A are either 0 or 1
  3. (C)Determinant of A is 1
  4. (D)A is invertible
Answer: A, B - show solution

A is the orthogonal projection onto span{x₁, ..., x₅}: Axᵢ = xᵢ for i = 1..5, and Av = 0 for v orthogonal to all of them. So A is symmetric with eigenvalues 1 (five times) and 0 (five times). For a symmetric positive semidefinite matrix the singular values equal the eigenvalues: (A) true, and they are 0 or 1: (B) true. A has rank 5 < 10, so det A = 0 and A is not invertible: (C), (D) false. Answer: (A), (B).

Concept: A sum of outer products of orthonormal vectors is a projection matrix (A² = A, Aᵀ = A). The trap is thinking it is the identity; it is only the identity when the vectors span the whole space.

Q51MSQ2 marks · no negative· Moderate

Let f : ℝ → ℝ be a twice-differentiable function and suppose its second derivative satisfies f''(x) > 0 for all x ∈ ℝ. Which of the following statements is/are ALWAYS correct?

  1. (A)f has a local minima
  2. (B)There does not exist x and y, x ≠ y, such that f'(x) = f'(y) = 0
  3. (C)f has at most one global minimum
  4. (D)f has at most one local minimum
Answer: B, C, D - show solution

f'' > 0 means f' is strictly increasing, so f' can vanish at most once: (B) true. Any local minimum of a differentiable function has f' = 0, so there is at most one local minimum: (D) true, and hence at most one global minimum: (C) true. (A) is not always true: f(x) = eˣ has f'' > 0 but f' = eˣ is never 0, so f has no minimum. Answer: (B), (C), (D).

Concept: Strict convexity forbids two stationary points but does not guarantee one exists. The trap is (A): eˣ is strictly convex yet has no minimum.

Q52MSQ2 marks · no negative· Moderate

An n × n matrix A with real entries satisfies the property: ‖Ax‖² = ‖x‖², for all x ∈ ℝⁿ, where ‖·‖ denotes the Euclidean norm. Which of the following statements is/are ALWAYS correct?

  1. (A)A must be orthogonal
  2. (B)A = I, where I denotes the identity matrix, is the only solution
  3. (C)The eigenvalues of A are either +1 or -1
  4. (D)A has full rank
Answer: A, D - show solution

‖Ax‖² = xᵀAᵀAx = xᵀx for all x. Since AᵀA - I is symmetric and its quadratic form is identically zero, AᵀA = I: A is orthogonal: (A) true. Orthogonal matrices are invertible, so A has full rank: (D) true. (B) false: -I or any rotation also works. (C) false: a 2-D rotation by 90° preserves length but has eigenvalues ±i; real eigenvalues of an orthogonal matrix are ±1, but eigenvalues can be complex with modulus 1. Answer: (A), (D).

Concept: Norm-preserving linear maps are exactly the orthogonal matrices. The trap is (C): eigenvalues have |λ| = 1, but they need not be real.

Q53MSQ2 marks · no negative· Moderate

Consider designing a linear binary classifier f(x) = sign(wᵀx + b), x ∈ ℝ² on the following training data: Class-1: (2, 0)ᵀ, (0, 2)ᵀ, (2, 2)ᵀ; Class-2: (0, 0)ᵀ Hard-margin support vector machine (SVM) formulation is solved to obtain w and b. Which of the following options is/are correct?

  1. (A)w = (4, 4)ᵀ and b = 1
  2. (B)The number of support vectors is 3
  3. (C)The margin is √2
  4. (D)Training accuracy is 98%
Answer: B, C - show solution

The closest point of Class-1's convex hull to the origin is (1, 1), the midpoint of (2, 0)-(0, 2), at distance √2. The maximum-margin boundary is the perpendicular bisector: x₁ + x₂ = 1. Scale so the support vectors satisfy |wᵀx + b| = 1: with w = (1, 1)ᵀ, b = -1, we get (2, 0) and (0, 2) at +1 and (0, 0) at -1, while (2, 2) gives 3. So (A) is false. Support vectors: (2, 0), (0, 2), (0, 0) - three: (B) true. Margin = 2/‖w‖ = 2/√2 = √2: (C) true. The data are separable, so hard-margin SVM gets 100% training accuracy: (D) false. Answer: (B), (C).

Concept: Hard-margin SVM: the margin width is 2/‖w‖ under the canonical scaling. The trap is (A): w = (4, 4), b = 1 does not even separate the data, since (0, 0) would score +1.

Q54MSQ2 marks · no negative· Easy

Consider a coin-toss experiment where the probability of head showing up is p. In the ith coin toss, let Xᵢ = 1 if head appears, and Xᵢ = 0 if tail appears. Consider p̂ = (1/n) Σ (i = 1 to n) Xᵢ where n is the total number of independent coin tosses. Which of the following statements is/are correct?

  1. (A)E[p̂] = p
  2. (B)E[p̂] = p/n
  3. (C)As n increases, variance of p̂ decreases
  4. (D)Variance of p̂ does not depend on n
Answer: A, C - show solution

E[p̂] = (1/n) Σ E[Xᵢ] = (1/n)(np) = p: (A) true, (B) false. Var(p̂) = (1/n²) Σ Var(Xᵢ) = (1/n²) · n p(1 - p) = p(1 - p)/n, which decreases as n grows: (C) true, (D) false. Answer: (A), (C).

Concept: The sample proportion is unbiased and its variance shrinks like 1/n. The trap is dividing the mean by n twice (option B).

Q55MSQ2 marks · no negative· Moderate

Consider a two-class problem in ℝᵈ with class labels red and green. Let μ_red and μ_green be the means of the two classes. Given test sample x ∈ ℝᵈ, a classifier calculates the squared Euclidean distance (denoted by ‖·‖²) between x and the means of the two classes and assigns the class label that the sample x is closest to. That is, the classifier computes f(x) = ‖μ_red - x‖² - ‖μ_green - x‖² and assigns the label red to x if f(x) < 0, and green otherwise. Which of the following statements is/are correct?

  1. (A)The sample x = 0 is assigned the label green if ‖μ_red‖ < ‖μ_green‖
  2. (B)f is a linear function of x
  3. (C)f(x) = wᵀx + b, where w and b are functions of μ_red and μ_green
  4. (D)f is a quadratic polynomial in x
Answer: B, C - show solution

Expand: ‖μ_red - x‖² = ‖μ_red‖² - 2μ_redᵀx + ‖x‖², and similarly for green. The ‖x‖² terms cancel: f(x) = 2(μ_green - μ_red)ᵀx + (‖μ_red‖² - ‖μ_green‖²). So f(x) = wᵀx + b with w = 2(μ_green - μ_red) and b = ‖μ_red‖² - ‖μ_green‖²: (B) and (C) true; it is not quadratic: (D) false. At x = 0, f = ‖μ_red‖² - ‖μ_green‖² < 0 when ‖μ_red‖ < ‖μ_green‖, so x = 0 is labelled red, not green: (A) false. Answer: (B), (C).

Concept: A nearest-mean classifier has a linear (hyperplane) decision boundary because the quadratic terms cancel. The trap is (D), reading the squared distances as making f quadratic.

Q56MSQ2 marks · no negative· Easy

Consider the following two relations, named Customer and Person, in a database: Which of the following statements is/are correct?

Person (
    aadhaar CHAR(12) PRIMARY KEY,
    name VARCHAR(32));
Customer (
    name VARCHAR(32),
    email VARCHAR(32) PRIMARY KEY,
    phone CHAR(10),
    aadhaar CHAR(12),
    FOREIGN KEY (aadhaar) REFERENCES Person(aadhaar));
  1. (A)aadhaar is a candidate key in the Customer relation
  2. (B)phone can be NULL in the Customer relation
  3. (C)aadhaar is a candidate key in the Person relation
  4. (D)aadhaar can be NULL in the Person relation
Answer: B, C - show solution

In Customer, aadhaar is only a foreign key with no UNIQUE constraint, so several customers (emails) may share one aadhaar; it is not a candidate key: (A) false. phone has no NOT NULL constraint, so it can be NULL: (B) true. In Person, aadhaar is the PRIMARY KEY, hence a candidate key: (C) true, and primary keys cannot be NULL: (D) false. Answer: (B), (C).

Concept: A foreign key need not be unique or non-null; a primary key is always unique and NOT NULL. The trap is assuming the referencing column inherits the key property of the referenced one.

Q57MSQ2 marks · no negative· Moderate

Consider a database relation R with attributes ABCDEFG, and having the following functional dependencies: A → BCEF E → DG BC → A Which of the following statements is/are correct?

  1. (A)A is the only candidate key of R
  2. (B)A, BC are the candidate keys of R
  3. (C)A, BC, E are the candidate keys of R
  4. (D)Relation R is not in Boyce-Codd Normal Form (BCNF)
Answer: B, D - show solution

A⁺ = A, B, C, E, F, then D, G from E: all of ABCDEFG, so A is a key. BC⁺ = B, C, A, then everything A gives: BC is a superkey; B⁺ = B and C⁺ = C, so BC is minimal - a candidate key. E⁺ = E, D, G only: not a key. D, F, G appear only on right sides, so any key must reach A; the candidate keys are exactly A and BC: (A), (C) false; (B) true. E → DG has a left side that is not a superkey, so R violates BCNF: (D) true. Answer: (B), (D).

Concept: Find keys with attribute closures and check minimality; BCNF requires every non-trivial FD's left side to be a superkey. The trap is missing BC as a key because BC → A is listed last.

Q58MSQ2 marks · no negative· Moderate

Let G be a simple, unweighted, and undirected graph. A subset of the vertices and edges of G is known: the vertices a, b, c, d, e, f, g, h with edges a-b, b-c, c-d, e-f, f-g, g-h, a-f, f-c, c-h. It is given that a - b - c - d is a shortest path between a and d; e - f - g - h is a shortest path between e and h; a - f - c - h is a shortest path between a and h. Which of the following is/are NOT the edges of G?

  1. (A)(b, d)
  2. (B)(b, g)
  3. (C)(b, h)
  4. (D)(e, g)
Answer: A, C, D - show solution

Each given shortest path has length 3, so no edge may create a shorter route between its endpoints. (b, d): a - b - d would have length 2 < 3. Not an edge. (b, h): a - b - h would have length 2 < 3. Not an edge. (e, g): e - g - h would have length 2 < 3. Not an edge. (b, g): it creates a - b - g - h (length 3, not shorter), and gives no shorter a-d or e-h path, so it may exist. Answer: (A), (C), (D).

Concept: An edge between two vertices of a shortest path that skips ahead would shorten it, so such edges cannot exist. The trap is ruling out (b, g), which only creates a path of equal length.

Q59NAT2 marks · no negative· Moderate

Let f : ℝ → ℝ be such that |f(x) - f(y)| ≤ (x - y)² for all x, y ∈ ℝ. Then f(1) - f(0) = ______ (Answer in integer)

Answer: 0 - show solution

Divide by |x - y|: |(f(x) - f(y))/(x - y)| ≤ |x - y|. Letting y → x gives f'(x) = 0 for every x, so f is constant and f(1) - f(0) = 0. (Directly: split [0, 1] into n equal parts; the total change is at most n · (1/n)² = 1/n for every n, hence 0.) Answer: 0.

Concept: A Hölder condition with exponent greater than 1 forces the derivative to vanish everywhere. The trap is applying the bound once with x = 1, y = 0 and answering 1.

Q60NAT2 marks · no negative· Moderate

Let D = {x⁽¹⁾, ..., x⁽ⁿ⁾} be a dataset of n observations where each x⁽ⁱ⁾ ∈ ℝ¹⁰⁰. It is given that Σ (i = 1 to n) x⁽ⁱ⁾ = 0. The covariance matrix computed from D has eigenvalues λᵢ = 100^(2-i), 1 ≤ i ≤ 100. Let u ∈ ℝ¹⁰⁰ be the direction of maximum variance with uᵀu = 1. The value of (1/n) Σ (i = 1 to n) (uᵀx⁽ⁱ⁾)² = ______ (Answer in integer)

Answer: 100 - show solution

The data are centred, so the covariance matrix is C = (1/n) Σ x⁽ⁱ⁾x⁽ⁱ⁾ᵀ, and (1/n) Σ (uᵀx⁽ⁱ⁾)² = uᵀCu, the variance of the data along u. The direction of maximum variance is the top eigenvector of C, and then uᵀCu equals the largest eigenvalue. λᵢ = 100^(2-i) decreases with i, so the largest is λ₁ = 100¹ = 100. Answer: 100.

Concept: The first principal component captures variance equal to the top eigenvalue of the covariance matrix. The trap is reading λᵢ as increasing in i and taking λ₁₀₀, or summing the eigenvalues.

Q61NAT2 marks · no negative· Easy

A bag contains 5 white balls and 10 black balls. In a random experiment, n balls are drawn from the bag one at a time with replacement. Let Sₙ denote the total number of black balls drawn in the experiment. The expectation of S₁₀₀ denoted by E[S₁₀₀] = ______ (Round off to one decimal place)

Answer: 66.6 to 66.7 - show solution

With replacement, each draw is black with probability 10/15 = 2/3, independently. S₁₀₀ ~ Binomial(100, 2/3), so E[S₁₀₀] = 100 × 2/3 = 66.67 ≈ 66.7 (key accepts 66.6 to 66.7, depending on truncating or rounding 66.666...).

Concept: Expectation of a binomial count is np, by linearity of expectation. The trap is using 10/5 as the probability or worrying about the bag emptying, which cannot happen with replacement.

Q62NAT2 marks · no negative· Moderate

Consider the following tables, Loan and Borrower, of a bank. Loan loan_num branch_name amount L11 Banjara Hills 90000 L14 Kondapur 50000 L15 SR Nagar 40000 L22 SR Nagar 25000 L23 Balanagar 80000 L25 Kondapur 70000 L19 SR Nagar 65000 Borrower customer_name loan_num Anand L11 Karteek L11 Karteek L14 Ankita L15 Gopal L19 Karteek L22 Karteek L23 Sunil L23 Sunil L25 Query: π_branch_name, customer_name(Loan ⋈ Borrower) ÷ π_branch_name(Loan) where ⋈ denotes natural join. The number of tuples returned by the above relational algebra query is ______ (Answer in integer)

Answer: 1 - show solution

The division returns customers who have a loan at every branch. Branches: Banjara Hills, Kondapur, SR Nagar, Balanagar. Anand: Banjara Hills only. Ankita: SR Nagar. Gopal: SR Nagar. Sunil: Balanagar (L23), Kondapur (L25). Karteek: Banjara Hills (L11), Kondapur (L14), SR Nagar (L22), Balanagar (L23) - all four. Result: {Karteek}, so 1 tuple.

Concept: Relational division answers 'for all' queries. The trap is counting customers with loans at many branches (Sunil) or counting loans rather than distinct branches.

Q63NAT2 marks · no negative· Moderate

Consider the following Python code snippet. The value printed by the code snippet is ______ (Answer in integer)

def f(a,b):
    if (a==0):
        return b
    if (a%2==1):
        return 2*f((a-1)/2,b)
    return b+f(a-1,b)
print(f(15,10))
Answer: 160 - show solution

b = 10 throughout. (a-1)/2 is a float in Python 3, but the comparisons still work (7.0 == 7). f(15) = 2 f(7); f(7) = 2 f(3); f(3) = 2 f(1); f(1) = 2 f(0); f(0) = 10. So f(1) = 20, f(3) = 40, f(7) = 80, f(15) = 160. The even branch b + f(a-1, b) is never reached. Printed value: 160 (as 160.0 in Python 3; the integer answer is 160).

Concept: Recursion tracing: unwind the calls to the base case and multiply back up. The trap is assuming the even branch is used, or worrying that / produces a float, which does not change the value.

Q64NAT2 marks · no negative· Moderate

Consider the following pseudocode. The value of sum output by a program executing the above pseudocode is ______ (Answer in integer)

Create empty stack S
Set x=0, flag=0, sum=0
Push x onto S
while (S is not empty){
    if (flag equals 0){
        Set x = x+1
        Push x onto S}
    if (x equals 8):
        Set flag=1
    if (flag equals 1){
        x = Pop(S)
        if (x is odd):
            Pop(S)
        Set sum = sum + x}
}
Output sum
Answer: 24 - show solution

While flag = 0 the loop pushes 1, 2, ..., 8, so S = [0, 1, ..., 8]. In the iteration that pushes 8, flag becomes 1, and from then on each iteration pops. Pop 8 (even): sum = 8. Pop 7 (odd), also pop 6: sum = 15. Pop 5, pop 4: sum = 20. Pop 3, pop 2: sum = 23. Pop 1, pop 0: sum = 24. S is empty, the loop ends. Answer: 24.

Concept: Stack trace with a conditional extra pop: odd values are added and the even value below them is discarded. The trap is adding every popped value (giving 36).

Q65NAT2 marks · no negative· Hard

Consider a directed graph G = (V, E), where V = {0, 1, 2, ..., 100} and E = {(i, j) : 0 < j - i ≤ 2, for all i, j ∈ V}. Suppose the adjacency list of each vertex is in decreasing order of vertex number, and depth-first search (DFS) is performed at vertex 0. The number of vertices that will be discovered after vertex 50 is ______ (Answer in integer)

Answer: 75 - show solution

Each vertex i has out-edges to i + 2 and i + 1, visited in that order. DFS from 0 always takes the +2 edge first: 0, 2, 4, ..., 100 are discovered in that order. 100 has no out-edges. Backtracking: 98's next neighbour 99 is new, discovered (its neighbour 100 is done). Then 96 discovers 97, and so on down to 0 discovering 1. Discovery order: 0, 2, ..., 100, then 99, 97, ..., 1. After 50: the evens 52, ..., 100 (25 vertices) and all 50 odd vertices. Total = 25 + 50 = 75.

Concept: Adjacency order decides the DFS path: the larger neighbour first means a dive along even vertices, and odd vertices are found only during backtracking. The trap is assuming 51 is found right after 50.

Answers are the official GATE answer key. Questions that depend on a figure are left out until they can be shown faithfully.