GATE Data Science & AI
130 questions · 3 years · 13 subjects
Public preview: use this branch page to find high-signal topics and keyed questions. Explanations are being added selectively, starting with recent and recurring concepts.
Subjects
By Year
High-yield topics
All trends →Practice Data Science & AI PYQs
40 questions shown in Computer Science. Filter for cleaner practice sessions.
Which of the following algorithms is NOT an example of uninformed search?
Which of the following statements is NOT true? (The names of the predicates are intuitive.)
Consider that the quick sort algorithm is used to sort an array of n distinct randomly ordered elements. In every call, the pivot is chosen as the first element of the current suba...
Consider the given Python program. def append_to_lst(val, lst=[]): lst.append(val) return lst print(append_to_lst(1)) print(append_to_lst(2)) print(append_to_lst(3, [])) Which of t...
Let R(A, B, C, D, E) be a relational schema with functional dependency set F={A→BC, CD→E, E→A}. Which of the following statements is correct?
Consider that the visualization of a 3-dimensional data cube is showing Sales Quantity for each combination of the attributes Product Type, Month and Country. From this, if we want...
Let M be a randomly chosen non-empty subset of S = {1,2,3,...,2026}. Which of the following is the probability that the product of all the elements of M is even?
Suppose that a computer program provides a non-negative and integer-valued random solution to the equation n₁ + n₂ + n₃ + n₄ = 20. Which of the following is the probability that al...
Let $M = \begin{pmatrix} \cos \theta & -\sin \theta \\ \sin \theta & \cos \theta \end{pmatrix}$ be a $2 \times 2$ matrix, where $\theta = \frac{2\pi}{5}$, and $I_2 = \begin{pmatrix...
Consider a set $S_1 = \{x = (x_1, x_2, x_3)^T \in \mathbb{R}^3 \mid x^T x \le 16\}$. Let $S_2$ be another set which is a subspace of $\mathbb{R}^3$ with dimension two. Which of the...
In the following table, the Task column lists a few tasks related to machine learning. The Algorithm column lists a few algorithms. Each entry "t" from the Task column is to be mat...
Sentence X is said to entail Sentence Y if whenever X is TRUE, Y also must hold TRUE. Which of the following statements is/are correct if X entails Y?
You are given the following Pre-order and In-order traversals of a Binary Tree T with nodes E, F, G, P, Q, R, S. Pre-order: P Q S E R F G In-order: S Q E P F R G Which of the follo...
Consider two relations r and s defined on the relational schemas R(A, B) and S(E, C), respectively. A is the primary key of R and E is a foreign key of S referencing A in R. Which...
Let A be a sorted array containing 1000 distinct integers. You perform a recursive binary search on A to find an element y. Suppose each comparison checks whether the middle elemen...
In a relational database, a B+ Tree Index is to be constructed for a relation on a key field. In a B+ Tree, a Node Pointer points to a sub-tree and a Data Record Pointer points to...
The number of bijections f(.) from the set S = {1, 2, 3, 4} to itself such that f(f(n)) = n, for all n ∈ S, is __________. (Answer in integer)
Let X be an exponentially distributed random variable with mean λ(> 0). If P(X > 5) = 0.35, then the conditional probability P(X > 10|X > 5) is __________. (Rounded off to two deci...
The value of $\Sigma_{i=0}^{\infty} \Sigma_{j=1}^{\infty} 2^{-i} 3^{-j}$ is __________. (Answer in integer)
Let four points in three-dimensional space be: P1: [2, 3, -1], P2: [3, 1, 1], P3: [5, -2, 3] and P4: [3, 3, 3]. Hierarchical Agglomerative Clustering is used to cluster the above p...
Which of the following statements is true for Ridge Regression?
Assume that a Creative (C) person will Succeed (S) if the person is also Disciplined (D), but will not succeed otherwise. Now, consider the following statements: (i) C ∧ S ⇔ D (ii)...
A recursive function in Python is given. def mystery(n): if n <= 0: return 1 else: return mystery(n-1) + mystery(n-2) Now, consider the following function call: mystery(4) Assume t...
Consider a directed graph $G = (V, E)$, where $V$ is the finite set of vertices and $E$ is the set of directed edges between the vertices. $G$ may contain cycles but there is no se...
Consider a B+ Tree where the maximum number of key values in each leaf node is 2 and the maximum number of pointers in each non-leaf node is 3. Let the content of the B+ Tree be as...
Consider the given relations X, Y and Z. The relation X has three columns P, Q and R. The relation Y has three columns P, Q and S. The relation Z has two columns P and T. Consider...
Consider the concept hierarchies as shown in the figure. Which of the following options denotes the total number of possible data cuboids from these concept hierarchies?
Consider that 20 stories of Author X and 10 stories of Author Y were kept together without mentioning the names of the authors. A classifier was then asked to predict the author (X...
Let P(x) be a predicate. Which of the following statements is/are NOT valid in first-order logic?
Consider the problem of sorting the given array in ascending order: P = [1, 2, 3, 5, 4] Consider two sorting algorithms Bubble Sort (BS) and Insertion Sort (IS). Let N1 be the tota...
Consider the given Python program. def outer(): x = [] def inner(val): x.append(val) return x return inner f1 = outer() f2 = outer() print(f1(10)) # Line P print(f1(20)) # Line Q p...
Consider a table Employee (EmpID, TeamID), where the column EmpID (ID of an employee) is the primary key. The column TeamID denotes the team ID of the team of which the employee is...
Let M = (I_n - (1/n)11^T) be a matrix, where 1 = (1,1,1, ...,1)^T ∈ R^n and I_n is the identity matrix of order n. Which of the following options is/are correct?
Let X_1,X_2,...,X_n be n independent random variables. Each of the random variables follows Normal(μ = 0, σ² = 1) distribution. Define X̄ = (1/n)Σ_{i=1}^n X_i . Which of the follow...
Consider a fully-connected feed-forward multi-layer perceptron. It has 30 neurons in the input layer, followed by two hidden layers and an output layer. The first hidden layer has...
A clinic specializes in testing for a disease D. The result of the test can be either positive or negative. A study revealed that if a person suffers from the disease D, the test r...
Consider the given Python program. def fun(L, i=0): if i >= len(L)-1: return 0 if L[i] > L[i+1]: L[i+1], L[i] = L[i], L[i+1] return 1+fun(L, i+1) else: return fun(L, i+1) data = [5...
Let there be two relations X and Y as shown. X has three columns P, Q and R. Y has two columns P and S. Consider that the following tuple relational calculus expression is evaluate...
Let Account be a relation as shown. Consider the given SQL query. SELECT AccNo FROM Account AS A WHERE (SELECT COUNT(*) FROM Account AS B WHERE A.Balance = (SELECT COUNT(*) FROM Ac...
Consider an ER model with the entities E1 (A11, A12, A13) and E2 (A21, A22, A23), where, A11, A12, A13 are the attributes of E1, and A21, A22, A23 are the attributes of E2. Let A22...