GATE 2026 Data Science and Artificial Intelligence (DA) Questions with Solutions

GATE 2026

65 questions

MCQ 33 · MSQ 14 · NAT 181-mark 30 · 2-mark 35

Questions 56–60 of 65

Q56Neural Networks2 marksNAT
Consider a fully-connected feed-forward multi-layer perceptron. It has 3030 neurons in the input layer, followed by two hidden layers and an output layer. The first hidden layer has 44 neurons and the second hidden layer has 33 neurons. The output layer has only one neuron. Assume that no bias parameters are used.

The number of learnable parameters in the multi-layer perceptron is ________. (Answer in integer)

Q57Probability and Bayes Theorem2 marksNAT
A clinic specializes in testing for a disease D\text{D}. The result of the test can be either positive or negative.

A study revealed that if a person suffers from the disease D\text{D}, the test result in that clinic comes out positive 80%80 \% of the time, and negative 20%20 \% of the time. If a person is not suffering from the disease D\text{D}, the test comes out positive 10%10 \% of the time and negative 90%90 \% of the time. It is also known that among the general population, the disease D\text{D} occurs in 30%30 \% of the individuals.

If a person tests positive for D\text{D} in that clinic, the probability that he/she actually suffers from the disease D\text{D} is ________. (Rounded off to two decimal places)

Q58Programming in Python2 marksNAT
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, 3, 4, 1, 2]
  count = 0
  for _ in range(len(data)):
  	count += fun(data)
  print(count) 
The output of the program is ________. (Answer in integer )

Q59Relational Algebra and Tuple Calculus2 marksNAT
Let there be two relations XX and YY as shown. XX has three columns P,QP, Q and R.YR . Y has two columns PP and SS.

X\textbf{X}
PQRP1Q1R1P2Q2R2P3Q3R2\begin{array}{|c|c|c|} \hline P & Q & R \\ \hline P1 & Q1 & R1 \\ \hline P2 & Q2 & R2 \\ \hline P3 & Q3 & R2 \\ \hline \end{array}

Y\textbf{Y}
PSP110P115P220P31\begin{array}{|c|c|} \hline P & S \\ \hline P1 & 10 \\ \hline P1 & 15 \\ \hline P2 & 20 \\ \hline P3 & 1 \\ \hline \end{array}

Consider that the following tuple relational calculus expression is evaluated.

{t∣t∈X∧∃z∈X(t[P]=z[P])∧∃m∈Y(m[P]=t[P]∧m[S]>1)}\{t \mid t \in X \wedge \exists z \in X(t[P]=z[P]) \wedge \exists m \in Y(m[P]=t[P] \wedge m[S]>1)\}

The number of tuples that will be returned is ________. (Answer in integer )

Q60SQL2 marksNAT
Let Account be a relation as shown.

Account\textbf{Account}
AccNoBalanceA15000A25000A310000A415000A518000\begin{array}{|c|c|} \hline \text{AccNo} & \text{Balance} \\ \hline \text{A1} & 5000 \\ \hline \text{A2} & 5000 \\ \hline \text{A3} & 10000 \\ \hline \text{A4} & 15000 \\ \hline \text{A5} & 18000 \\ \hline \end{array}

Consider the given SQL query.
SELECT AccNo FROM Account AS A
  WHERE (SELECT COUNT(*) FROM Account AS B
  WHERE A.Balance < B.Balance) >= (SELECT COUNT(*)
  FROM Account AS C WHERE A.Balance > C.Balance) 
The number of rows returned by the SQL query is ________. (Answer in integer)