MauryaHub PYQ Practice

Computational Thinking · End Term · May 2026 · AN

Computational Thinking · End Term · May 2026 AN

← Course papers · Start practice / exam

Questions and published explanations below are available without starting a test. Some questions may not have a published solution yet.

0 / 21 published solutions

Question 2 MCQ · 0.0 marks

Source diagram or notation
Source diagram or notation
6406537406432.
Useful Data has been mentioned above.
6406537406433.
This data attachment is just for a reference & not for an evaluation.

A published solution is not available for this question yet.

Report a correction for Q2

Question 3 MCQ · 5.0 marks

The following pseudocode is executed using the "**Words**" dataset. Assume that each sentence in the dataset ends with a full stop. Ignore the upper and lower case, and punctuation symbols while comparing with other words. What will **minWord** represent at the end of the execution?
Source diagram or notation
6406537406434.
A list of words with the lowest overall frequency across all sentences.
6406537406435.
A list containing the lowest frequency words from each sentence.
6406537406436.
A list of words with the lowest overall frequency across all sentences not ending with a question mark.
6406537406437.
A list containing the last word of every sentence evaluated in the dataset.

A published solution is not available for this question yet.

Report a correction for Q3

Question 4 MCQ · 5.0 marks

Consider the "**Scores**" dataset. What will **targetCity** represent at the end of the execution of the pseudocode?
Source diagram or notation
6406537406438.
The city with the maximum difference between its highest Mathematics score and lowest Physics score.
6406537406439.
The city with the maximum difference between its highest Physics score and lowest Mathematics score.
6406537406440.
The city with the maximum difference between its highest Physics score and highest Mathematics score.
6406537406441.
The city with the maximum difference between its lowest Physics score and lowest Mathematics score.

A published solution is not available for this question yet.

Report a correction for Q4

Question 5 MCQ · 5.0 marks

The following pseudocode is executed using the “**Library**” dataset. What does **authorsCount** represent at the end of the execution?
Source diagram or notation
6406537406442.
Number of authors who have published more than one book.
6406537406443.
Number of authors who have published books in more than one distinct genre.
6406537406444.
Number of genres that have more than one author.
6406537406445.
Total number of distinct books written by multi-genre authors.

A published solution is not available for this question yet.

Report a correction for Q5

Question 6 MCQ · 5.0 marks

Let **Z** be a row in the "Words" table such that **Z.Word = "statistics"**. What will the value of **Dict['t']** be at the end of the execution?
Source diagram or notation
6406537406446.
-1
6406537406447.
0
6406537406448.
1
6406537406449.
2

A published solution is not available for this question yet.

Report a correction for Q6

Question 7 MCQ · 5.0 marks

The following pseudocode is executed using the "**Words**" dataset. Assume that the rows in Table 1 are sorted in the increasing order of sequence number.
Source diagram or notation
What does the list **L** contain at the end of execution?
6406537406450.
The list of nouns that come immediately after an adjective
6406537406451.
The list of adjectives that come immediately after a noun
6406537406452.
The list of nouns that come immediately before an adjective
6406537406453.
The list of adjectives that come immediately before a noun

A published solution is not available for this question yet.

Report a correction for Q7

Question 8 MCQ · 4.0 marks

The following pseudocode is executed using the "**Shopping Bills**" dataset. At the end of the execution, the variable D captures the following information: for each customer Z, D[Z]["Shop"] stores the shops visited by Z, and D[Z]["Category"] stores the categories of the items purchased by Z. But the pseudocode may have mistakes. Identify all such mistakes (if any). 1 D = {} 2 while (Pile 1 has more cards) { 3 Read the top card X in Pile 1 4 D = updateDictionary(D, X) 5 Move X to Pile 2 6 } 7 8 Procedure updateDictionary(D, Y) 9 if (not isKey(D, Y.CustomerName)) { 10 D[Y.CustomerName] = {"Shop": [], "Category": []} 11 } 12 D[Y.CustomerName]["Shop"][Y.ShopName] = True 13 foreach A in Y.ItemList { 14 D[Y.CustomerName]["Category"][A.Category] = True 15 } 16 return(D) 17 End updateDictionary
6406537406462.
Error in Line 1
6406537406463.
Error in Line 10
6406537406464.
Error in Line 13
6406537406465.
Error in Line 14
6406537406466.
Error in Line 16
6406537406467.
No errors

A published solution is not available for this question yet.

Report a correction for Q8

Question 9 MCQ · 4.0 marks

Consider the procedure given below.
Source diagram or notation
If L1 and L2 are two lists, and L = eliminate(L1, L2), choose the correct option regarding L.
6406537406485.
It will contain all the elements of L2 that are not present in L1
6406537406486.
It will contain all the elements of L1 that are not present in L2
6406537406487.
It will contain all the elements common to L1 and L2
6406537406488.
It will contain the elements present in L1 or L2 but not both

A published solution is not available for this question yet.

Report a correction for Q9

Question 10 MSQ · 5.0 marks

The following pseudocode is executed using the "**Scores**" table.
Source diagram or notation
Which of the following statements are true about the dictionary **D**?
6406537406454.Source diagram or notation
gives the total number of male students from Chennai who scored more than 80 in both Mathematics and Physics.
6406537406455.
If a city has no students scoring more than 80 in both subjects, the city will still appear as a key in the dictionary with value 0.
6406537406456.Source diagram or notation
can be at most 2.
6406537406457.Source diagram or notation
is a dictionary mapping cities to the number of female students from those cities who met the score condition.

A published solution is not available for this question yet.

Report a correction for Q10

Question 11 MSQ · 5.0 marks

The given pseudocode is executed using the "Scores" dataset. Here, Sequence Number of cards, starts from 0. **matrix** represents an adjacency matrix.
Source diagram or notation
Which of the following statements is/are TRUE?
6406537406458.
The graph represented by
Source diagram or notation
is a directed graph where
Source diagram or notation
might not equal
Source diagram or notation
.
6406537406459.
The graph represented by
Source diagram or notation
is an undirected graph.
6406537406460.Source diagram or notation
implies students
Source diagram or notation
and
Source diagram or notation
are of different genders and their total scores differ by at most 10.
6406537406461.
A student
Source diagram or notation
can have
Source diagram or notation
.

A published solution is not available for this question yet.

Report a correction for Q11

Question 12 MSQ · 5.0 marks

Consider a graph generated from the "**Scores**" table that is represented by a matrix B. Each node in the graph corresponds to a student from the table. SeqNo is used to label the nodes in the graph and SeqNo starts from 0. Study the given pseudocode and answer the following questions.
Source diagram or notation
Which of the following statements are true about this graph?
6406537406468.
There are two cliques in this graph, one for each gender
6406537406469.
In every clique, there is at least a pair of students having different genders
6406537406470.
All students in a given clique have the same gender
6406537406471.
All students in a given clique are from the same city/town
6406537406472.
There are no cliques in this graph

A published solution is not available for this question yet.

Report a correction for Q12

Question 13 MSQ · 5.0 marks

The following pseudocode is executed using the “**Shopping Bills**” dataset.
Source diagram or notation
Which of the following statements is/are true at the end of the execution?
6406537406477.Source diagram or notation
contains the total cost of all bills for each customer.
6406537406478.Source diagram or notation
maps a customer's name to the number of times they had a single bill exceeding 500 in cost.
6406537406479.
A customer will not be in
Source diagram or notation
if each of their individual bills had a total cost of 500 or less.
6406537406480.Source diagram or notation
contains the average cost of all bills for each customer.

A published solution is not available for this question yet.

Report a correction for Q13

Question 14 MSQ · 6.0 marks

**Mix** is a recursive procedure that interleaves two lists. If the lists have different lengths, the remaining elements of the longer list are appended at the end. Select the correct code fragment(s) to complete the pseudocode.
Source diagram or notation
**Examples:** •
Source diagram or notation
returns
Source diagram or notation
. •
Source diagram or notation
returns
Source diagram or notation
. •
Source diagram or notation
returns
Source diagram or notation
.
6406537406473.Source diagram or notation
6406537406474.Source diagram or notation
6406537406475.Source diagram or notation
6406537406476.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q14

Question 15 MSQ · 6.0 marks

Consider the following pseudocode which processes a list of words.
Source diagram or notation
Which of the following statements is/are TRUE at the end of the execution?
6406537406481.
The list
Source diagram or notation
contains exactly the same elements as
Source diagram or notation
but in sorted order.
6406537406482.
The list
Source diagram or notation
contains exactly the distinct words found in
Source diagram or notation
, preserving their first appearance order.
6406537406483.Source diagram or notation
will have a value of 3.
6406537406484.Source diagram or notation
is equal to
Source diagram or notation
.

A published solution is not available for this question yet.

Report a correction for Q15

Question 16 NAT · 6.0 marks

Consider the following pseudocode for a mathematical procedure. Assume **a** and **b** are positive integers.
Source diagram or notation
What is the return value of
Source diagram or notation
?

A published solution is not available for this question yet.

Report a correction for Q16

Question 17 NAT · 5.0 marks

What will the value of **S** be at the end of the execution of the following pseudocode?
Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q17

Question 18 NAT · 5.0 marks

Consider the following procedure.
Source diagram or notation
What will be the return value of **mysterySum(304)**?

A published solution is not available for this question yet.

Report a correction for Q18

Question 19 MCQ · 5.0 marks

Let **M** be the adjacency matrix of the following directed graph **G**.
Source diagram or notation
Consider the following pseudocode, where
Source diagram or notation
represents the list of all vertices in **G**:
Source diagram or notation
Based on the above data, answer the given subquestions.
What does the procedure **countPaths** calculate?
6406537406492.
The maximum length of a directed path in the graph.
6406537406493.
The number of paths of length 2 where there is no direct edge between the starting and ending vertices.
6406537406494.
The number of paths of length exactly 3.
6406537406495.
The number of vertices that have no outgoing edges.

A published solution is not available for this question yet.

Report a correction for Q19

Question 20 NAT · 5.0 marks

Let **M** be the adjacency matrix of the following directed graph **G**.
Source diagram or notation
Consider the following pseudocode, where
Source diagram or notation
represents the list of all vertices in **G**:
Source diagram or notation
Based on the above data, answer the given subquestions.
Based on the graph **G** and procedure **countPaths(M)** provided in the previous question, what will be the return value of **countPaths(M)**?

A published solution is not available for this question yet.

Report a correction for Q20

Question 21 MCQ · 5.0 marks

Let **H** be the adjacency matrix of the following directed graph **K**.
Source diagram or notation
Consider the following pseudocode, where
Source diagram or notation
represents the list of all vertices in **K**:
Source diagram or notation
Based on the above data, answer the given subquestions.
What does the procedure **analyzeGraph** compute?
6406537406497.
The list of vertices from which every other vertex is reachable in at most 2 steps.
6406537406498.
The list of vertices that can be reached by every other vertex in at most 2 steps.
6406537406499.
The list of vertices from which every other vertex is reachable in exactly 2 steps.
6406537406500.
The list of vertices that have an outgoing edge to every other vertex in the graph.

A published solution is not available for this question yet.

Report a correction for Q21

Question 22 NAT · 4.0 marks

Let **H** be the adjacency matrix of the following directed graph **K**.
Source diagram or notation
Consider the following pseudocode, where
Source diagram or notation
represents the list of all vertices in **K**:
Source diagram or notation
Based on the above data, answer the given subquestions.
Based on the graph **K** and procedure **analyzeGraph(H)** provided, what will the value of
Source diagram or notation
be?

A published solution is not available for this question yet.

Report a correction for Q22