Syllabus Merged
Syllabus Merged
The entrance examination will primarily check mathematical aptitude and the ability to
logically interpret data. Candidates should be familiar with following topics:
Suggested textbooks
There are many books that cover this material. The questions asked will only test basic
concepts. Here are a few suggestions.
Exam pattern
The exam will have 40 questions to be solved in 3 hours. Of these, 20 questions will be objective type
(multiple choice, or fill in the blank with a single number/expression) and 20 questions will be short
answer type (calculate an answer and give a brief justification). The objective type problems carry 2
points each (with no partial credit) and the short answer type problems carry 3 points each (partial
credit possible). The total number of points is 100.
Here are some questions indicative of the level and scope of the exam.
Notation
• A function f from a set A to a set B is said to be injective (or one-to-one) if f (x) = f (y)
implies x = y for all x, y ∈ A;
• f is said to be surjective (or onto) for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all
y ∈ B and g(f (x)) = x for all x ∈ A.
• For a matrix A, |A| denotes the determinant of A and AT denotes the transpose of A.
a b α β
1. If A = and A2 = , then which of the following is/are true?
b a β α
(a) α = a2 + b2
(b) β = 2ab
(c) α = a2 − b2
(d) β = −2ab
2. A function y = f (x) is said to be even if f (−x) = f (x) for every x. For example, f (x) = x2 is
an even function. Which of the following are even functions?
ex − 1
(a)
ex + 1
ax + a−x
(b) , where a > 0
2
(c) x2 − |x|
1
1 − x
(d) log
1+x
4. Sushma has 2 children. Let A be the event that the elder child is a girl, B be the event that at
least one child is a girl and C be the event that both children are girls. Which of the following
are correct statements?
(a) P (C | A) = 21 .
(b) P (C | B) = 21 .
(c) P (C | A) = 13 .
(d) P (C | B) = 31 .
5. Let X represent the lifetime of a mobile phone model. The probability that a phone will have a
lifetime of more than a years is given by the following formula.
Z ∞
P (X > a) = λe−λx dx, where λ = 0.5
a
6. Let S denote the set of all employees in a large corporation. For i, j ∈ S, let A(i, j) = 1 if j
reports to i and is 0 otherwise. A(i, i) = 0 by definition. Which of the following statements
is/are true?
X
(a) A(i, j) ≤ 1 for all j ∈ S
i∈S
X
(b) A(i, j) ≤ 1 for all i ∈ S
i∈S
X
(c) A(i, j) ≥ 1 for all j ∈ S
i∈S
XX
(d) A(i, j) = n.
i∈S j∈S
It turns out the jabberwock is not mimsy. Therefore it must be the case that
2
(a) The jabberwock is not borogove.
(b) The jabberwock is not a slithy tove.
(c) The jabberwock is neither borogove nor a slithy tove.
(d) The jabberwock may be either borogove or a slithy tove.
8. Avinash is taller than Abhay. Bharat is taller than Vinu and Vinay is taller than Bharat. Which
of the following additional pieces of information can determine the tallest person? (Select all
that apply.)
Description for next two questions: The bar graph given below shows the sales of non-
fiction books of an on-line store, during two consecutive years 2016 and 2017, for four states of
India.
(a) The ratio of the total sales of Karnataka for both years to the total sales of TamilNadu for
both years is 41:37.
(b) The total sales for the year 2017 is Rs. 335/-
(c) The average sales in 2016 is 89.33% percent of the average sales of 2017.
(d) The average sales in southern India over two years is Rs 355/-.
3
(d) Overall growth in book sales is 11.9%
Description for next four questions: In an exam 43% passed in Mathematics, 52% passed
in Physics and 52% passed in Chemistry. Only 8% students passed in all the three. 14% passed
in Mathematics and Physics and 21% passed in Mathematics and Chemistry and 20% passed in
Physics and Chemistry. The number of students who took the exam is 200.
12. What is the ratio of students passing only in Mathematics to the students passing only in
Chemistry?
13. What is the ratio of the number of students passing only in Physics to the students passing in
either Physics or Chemistry or both?
14. A student is declared to have passed in the exam only if he/she passes at least two subjects.
How many students were declared to have passed in the exam?
15. In the code fragment below, i0, j0, k0, start and end are integer values and prime(x) is a
function that returns True if x is a prime number.
At the end of the loop which of the following are valid statements about the relationship between
the different values in the program for any choice of i0, j0, k0, start and end? Note that %
denotes the modulus operator: a%b is the remainder when integer a is divided by integer b.
4
16. What does the following function compute in terms of n and d, where n and d are both assumed
to be integers?
function f(n,d) {
if (d == 0) {
return(1)
} else if (d < 0) {
return(f(n,d+1)/n))
} else {
return(n*f(n,d-1))
}
}
cos θ sin θ
4. Find the value of f (π/6), where f (θ) = .
sin θ cos θ
5. Given the sets A = {1, 2, −3, 4} and B = {1, 3, 5, 7}, is f (x) = 2x − 1 a well-defined function
from A to B? Give reasons for your answer.
6. Consider the function f : R → R defined by f (x) = (ex − e−x ). Is f an invertible function? Give
reasons for your answer.
7. In a group of 50 students, what is the probability that at least two students share the same
birthday? (You can assume that none of the students is born on Feb 29). Give explanation for
your answer.
5
8. Hospital records show that 75% of patients suffering from a disease die due to that disease.
What is the probability that 4 out of 6 randomly selected patients recover?
9. A group of 60 students is randomly split into 3 classes of equal size. All partitions are equally
likely. What is the probability that Jack and Jill will end up in the same class?
10. Do the three lines 2x1 + 3x2 = 1, x1 + x2 = 0 and 2x1 − 5x2 = 7 intersect in a common point?
Give reasons for your answer.
11. For what value(s) of h can the vector v be expressed as a linear combination of {v1 , v2 , v3 } where
1 5 −3 −4
v1 = −1 , v2 = −4 , v3 = 1 , and v = 3
−2 −7 0 h
12. Is the following statement true: Let A be an n × n matrix. If AT is not invertible then A is also
not invertible. Give justification for your answer.
T
QT
P Q T P
13. Is the following statement true: If A = , then the transpose of A is A = .
R S RT S T
Give justification for your answer.
14. Is the following statement true: If A is an invertible matrix, then A + AT is invertible. Give
justification for your answer.
15. Is the following statement true: Suppose A and B are n × n matrices such that AB is invertible.
Then both A and B are invertible. Give justification for your answer.
16. Is the following statement true: let I be a k × k identity matrix, 0is the k× k matrix with all
I 0
0’s and A is an arbitrary k × k matrix. Then the 2k × 2k matrix is invertible. Give
A I
justification for your answer.
17. Suppose A and B are n × n matrices such that all elements in the last column of B are zeroes.
Compute the last column of the matrix AB.
18. A touring cricket team has 15 players, comprising 6 specialist batsmen, 5 specialist bowlers, 2
all-rounders and 2 wicket-keepers. It is time to select the team for the next match. A team
consists of 11 players and the desired composition is 5 specialist batsmen, 4 specialist bowlers,
1 all-rounder and 1 wicket-keeper. In how many ways can such a team be selected?
19. There are 60 students in the class and each knows at least one programming language among
Java, C++ and Python. 40 students know at least two of the languages and 10 know all three.
How many students know exactly one programming language?
20. Varsha lives alone and dislikes cooking, so she goes out for dinner every evening. She has two
favourite restaurants, Dosa Paradise and Kababs Unlimited, to which she travels by local train.
The train to Dosa Paradise runs every 10 minutes, at 0, 10, 20, 30, 40 and 50 minutes past
the hour. The train to Kababs Unlimited runs every 20 minutes, at 8, 28 and 48 minutes past
the hour. She reaches the station at a random time between 7:15 pm and 8:15 pm and chooses
between the two restaurants based on the next available train. What is the probability that she
ends up eating in Kababs Unlimited ?
21. An advertisement for a tennis magazine states, “If I’m not playing tennis, I’m watching tennis.
And if I’m not watching tennis, I’m reading about tennis.” We can assume that the speaker can
do at most one of these activities at a time. What is the speaker doing? Give reasons for your
answer.
6
(b) Watching tennis.
(c) Reading about tennis.
(d) None of the above.
22. Ball Mart has 107 different items in stock across all its stores worldwide. The company has
collected billing data for 1010 customer transactions. Each individual bill has at most 10 distinct
items in it.
Ball Mart’s CEO wants to optimize the company’s inventory and has asked for a list of those
items that appear in at least 2% of the billed transactions. Which of the following is the most
precise upper bound one can compute for the number of such items, given the data?
(a) 500
(b) 1000
(c) 5000
(d) 20000
23. An ant starts at the origin (0,0), facing north. On day 1, it moves 1 unit forward to (0,1) and
turns right 90 degrees. On day 2, it moves 2 units forward to (2,1) and turns right 90 degrees.
On day 3, it moves 3 units forward to (2,-2) and turns right 90 degrees. It keeps doing this—on
day i, it moves i units forward and turns right 90 degrees. After 65 days, where is the ant?
24. You have k feet of fence to make a rectangular play area alongside the wall of your house. The
wall of the house bounds one side. What is the largest size possible (in square feet) for the play
area?
25. Suppose a new airline is offering promotional air fares for travel between various cities are as
follows:
If a passenger living in Delhi wishes to visit Mumbai, Pune, Kolkata and Chennai and return to
Delhi. What route should she follow and what would be her cost. Justify your answer.
26. Assume that the relation “friend” is symmetric. Show that if n ≥ 2, then in any group of n
people there are at least two with the same number of friends in the group.
7
27. The function below takes three integer arguments. It is supposed to return the minimum of
these three values.
function min3(x,y,z) {
if (x <= y) {
if (x <= z) {
minimum := x
}
}
else {
if (y <= z) {
minimum := y
}
else {
minimum := z
}
}
return(minimum)
}
There is an error in the function. Find values x, y, z for which min3(x,y,z) fails to return the
correct value and explain the error.
8
Solutions
Objective type questions
Explanations are provided for some questions to aid understanding. In the exam, no explanations are
required for these type of questions.
5. (a) and (b) are False, (c) and (d) are True
(a) would be correct if the terms were reversed. (b) is the probability that the lifetime is more
than 5 years.
8. (a) Avinash is taller than Vinay and (c) Vinay is shorter than Abhay.
We are given that Avinash is taller than Abhay and Vinay is taller than Bharat who is taller than
Vinu. We need to resolve which of Avinash and Vinay is taller. (a) gives us this information
directly. (c) tells us that Vinay is shorter than Abhay who is known to be shorter than Avinash,
so Vinay is shorter than Avinash. The other two choices do not unambiguously resolve which of
Avinash and Vinay is taller.
9. (a) True
(95 + 110) 205 41
Required Ratio = = = .
(80 + 105) 105 37
(b) False
Rs 335/- is the sales of year 2017.
(c) True
Average sales in 2016 (85 + 95 + 75 + 80)/4 = 335/4;
Average sales in 2017 (95 + 110 + 65 + 105)/4 = 375/4;
335/4
Required percentage = × 100 ≈ 89.33%.
375/4
(d) True
9
(d) True
11. 32
12. 16:19
13. 26:84
14. 78
so the image of the x-axis is again the x-axis. Hence A maps the x-axis to itself.
0
2. Points on the y-axis are of the form for y ∈ R. So
y
0 1 0 y
= .
1 0 y 0
Thus the image of the line y = x under the function defined by C is the line y = 4x.
5. f (−3) = −7, but −7 does not belong to B, so the function is not a well defined function from
A to B. For the other three values in A, we have f (A) ∈ B.
6. Here limx→∞ f (x) = ∞ and limx→−∞ f (x) = −∞. Since f is a continuous function, it follows
that f is surjective. Further, since f 0 (x) = ex + e−x > 0 for all x, f is strictly increasing and
hence f is injective. Thus f is a bijective function and hence admits an inverse.
10
7. The required probability equals 1 minus the probability that all 50 have distinct birthdays.
365
P 50
Hence the answer is 1 − .
36550
8. The required probability equals observing 4 successes (survivors) in 6 independent trials. This is
a binomial distribution with n = 6, x = 4, p = 0.25 (probability of living (success)) and q = 0.75
(probability of dying (failure)).
If X is the number number of survivors, then P (X = x) = nx px (1 − p)n−x . Thus the required
9. 19/59. Assign a different number to each student from 1 to 60. Numbers 1 to 20 go in group
1, 21 to 40 go to group 2, 41 to 60 go to group 3. All possible partitions are obtained with equal
probability by a random assignment if these numbers, it doesn’t matter with which students we
start, so we are free to start by assigning a random number to Jack and then we assign a random
number to Jill. After Jack has been assigned a random number there are 59 random numbers
available for Jill and 19 of these will put her in the same group as Jack. Therefore the probability
is 19/59.
10. Solving the first two equations simultaneously gives x2 = 1 and x1 = −1. These values of x1 and
x2 do not satisfy the third equation (since 2x1 − 5x2 = −7 6= 7); thus the system is inconsistent
and does not have a common solution. Another way to solve this would be to consider the
augmented matrix
2 3 | 1
1 1 | 0
2 −5 | 7
and apply row reduction to get
2 3 | 1
0 −1/2 | −1/2 .
0 0 | 14
This system has no solution, since no value of x1 , x2 will satisfy 0(x1 ) + 0(x2 ) = 14.
11. The question is same as the following : when does the system of equations x1 v1 +x2 v2 +x3 v3 = v
admit a solution? Now solve the system to get the answer h = 5.
15. True: We know that |AB| = |A| · |B|. If any one of A or B is not invertible, i.e. one of |A| or
|B| equals zero, then |AB| would equal zero, a contradiction to the fact that AB is invertible.
I 0
16. True: the matrix is upper triangular, so its determinant is just the product of its
A I
diagonal entries, hence the determinant equals 1 and hence it is invertible.
17. The last column of AB will also consist of zeroes since for all 1 ≤ i ≤ n:
n
X
(AB)in = ((A)ik + (B)kn ) .
k=1
11
18. 120. There are 6 ways to choose 5 out of 6 batsmen, 5 ways to choose 4 out of 5 bowlers, 2 ways
to choose 1 out of 2 all-rounders and 2 ways to choose 1 out of 2 wicket-keepers. These choices
are independent, so multiply 6 · 5 · 2 · 2 to get 120. Alternatively, there are 6 ways to choose one
batsman to drop, 5 ways to choose one bowler to drop, 2 ways to choose 1 all-rounder to drop
and 2 wayS to choose 1 wicket-keeper to drop, so again 6 · 5 · 2 · 2 = 120.
19. 20. Since 40 students know at least two programming languages and each one knows at least one
language, there are 20 who know exactly one. The fact that 10 know all three is irrelevant.
2
20. .
5
If Varsha arrives in the intervals 7:20–7:28, 7:40–7:48, or 8:00–8:08, the next train goes to
24 2
Kababs Unlimited. This adds up to 24 minutes out of a total of 60 minutes so = is the
60 5
probability that she ends up having dinner at Kababs Unlimited
23. (-32,33)
Each pair of odd numbered moves (1, 3), (5, 7), . . . results in a net y-displacement of −2. Each
pair of even numbered moves (2, 4), (6, 8), . . . results in a net x-displacement of −2. After 64
days, the ant has made 16 pairs of odd numbered moves and 16 pairs of even numbered moves,
so the net displacement is (−32, −32). Move 65 takes it to (−32, 33).
25. The cheapest flights in each row are - Mumbai to Pune (2500), Delhi to Kolkata (3200), Chennai
to Mumbai (3000), Kolkata to Chennai (3300) and Pune to Mumbai as well as to Delhi (3000).
Thus, the cheapest routing is Delhi - Kolkata - Chennai - Mumbai - Pune - Delhi with the cost
2500+3200+3000+3300+3000=15000.
26. Any person in the group can have 0 to (n − 1) friends. If someone has 0 friends, then no one
has (n − 1) friends and if someone has (n − 1) friends then no one has 0 friends. Hence the
number of possibilities for the number of friends the n people in the group have must be either
0, 1, . . . , (n − 2) or 1, 2, . . . , (n − 1). In each case there are (n − 1) possibilities and n people.
Hence at least two people in the group must have the same number of friends.
27. The function fails when z < x < y. For example, min3(8,11,4). In this situation, minimum is
not assigned any value. Since x < y, the first if condition succeeds, and since x > z, the nested
if fails and the function exits the outer if without assigning any value to minimum.
12
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination
15th May 2018
D − −
Enter your Admit Card Number :
IMPORTANT INSTRUCTIONS
• This booklet has 8 printed sheets, including this cover page. Sheet 2 (page 1) contains space to answer
part A, sheets 3 to 5 contain twenty questions in part A and sheets 6 to 8 contain twenty questions in
part B.
– For questions in part (A), you only have to write your answer on the designated page on the appro-
priate line. For example, if the answer is parts (a) and (c), write only (a) and (c) on the line and
if the answer is 2781, write this number on the line.
– For questions in part (B), you have to write your answer with short explanation in the space provided
below the question.
– For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr ,
n P , n! etc.
r
• Time allowed is 3 hours. Total points: 100 = 40 for part A + 60 for part B.
• Part A will be used for screening. Part B will be graded only if you score a certain minimum in part
A. However your scores in both parts will be used while making the final decision.
Points Remarks
Part A
Part B
Total
B1 B2 B3 B4 B5 B6 B7 B8 B9 B10 Total
B11 B12 B13 B14 B15 B16 B17 B18 B19 B20 Total
Part A - Answers
This is the only place that will be seen for grading part A. So carefully and clearly write the
answers to each question on the designated line below. Write only the final answers, do not show any
intermediate work. Illegible/unclear answers will not be considered.
A1. A11.
A2. A12.
A3. A13.
A4. A14.
A5. A15.
A6. A16.
A7. A17.
A8. A18.
A9. A19.
A10. A20.
1
Notation
• A function f from a set A to a set B is said to be injective (or one-to-one) if f (x) = f (y)
implies x = y for all x, y ∈ A;
• f is said to be surjective (or onto) if for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all
y ∈ B and g(f (x)) = x for all x ∈ A.
• For a matrix A, |A| denotes the determinant of A and AT denotes the transpose of A.
Part A - Questions
This section consists of some questions requiring a single answer and some multiple choice
questions. For questions that ask you to calculate a value, you will be assessed based on the
answer you provide. No explanation is required. In multiple choice questions, there may be
multiple correct choices.
You have to select all the correct options and no incorrect option to get full marks.
There is no partial credit. Write the correct options / answer in the space provided
on page 1. Only page 1 will be seen for grading part A.
(a) B = P −1 AP
(b) |A| = |B|
(c) A is invertible if and only if B is invertible
(d) B T = AT .
1 2 3 1 4 7 4 5 6 −1 2 3
2. Let A = 4 5 6 , B = 2 5 8 , C = 1 2 3 and D = 4 −5 6 .
7 8 9 3 6 9 7 8 9 7 8 −9
3
3. Let x = 3 1 2 . Which of the following statements are true?
(a) xT x is a 3 × 3 matrix
(b) xxT is a 3 × 3 matrix
(c) xxT is a 1 × 1 matrix
(d) xxT = xT x
0 AT
A 0
(b) (d)
A 0 0 AT
where Φ(a = −2) = 0.02, Φ(a = −1) = 0.16, Φ(a = 0) = 0.50, Φ(a = 1) = 0.84, and
Φ(a = 2) = 0.98. Note that X = µ + σZ follows normal distribution with mean µ and standard
deviation σ. The length of the life of an instrument produced by a machine has a normal
distribution with a mean of 24 months and standard deviation of 2 months.
5. The probability that an instrument produced by this machine will last less than 18 months is
Z 18
exp{−z 2 /2}
(a) √ dz.
−∞ 2π
Z ∞
exp{−z 2 /2}
(b) √ dz.
18 2π
(c) is less than 0.02.
( )
1 x − 24 2
Z 18
1
(d) √ exp − dx.
−∞ 2π.22 2 2
6. The probability that an instrument produced by this machine will die between 18 and 24 months
is
4
7. Out of a large number of instruments produced by this machine, the percentage of instruments
that will last more than 26 months approximately
Description for the following four questions: Given below is the time table for a trans-
continental train cutting across several time zones. All times given below are local time in
respective cities. It is given that the average speed between any two cities is the same for both
way journeys.
8. Which of the following pairs of cities are in the same time zone?
9. Write down the total time taken in minutes by the train to go from Zut to Raz.
5
12. In an entrance examination with multiple choice questions, with each question having four
options and a single correct answer, suppose that only 20% candidates think they know the
answer to one difficult question and only half of them know it correctly and the other half get it
wrong. The remaining candidates pick one option out of the four randomly and tick the same.
If a candidate has correctly answered the question, what is the (conditional) probability that
she knew the answer?
13. There are n songs segregated into 3 play lists. Assume that each play list has at least one song.
The number of ways of choosing three songs consisting of one song from each play list is:
n3
(A) > for all n
27
n3
(B) ≤ for all n
27
(C) n3 for all n
14. Consider the following functions defined from the interval (0, 1) to real numbers. Which of these
functions attain their maximum value in the interval (0, 1)?
1
(a) f (x) =
x(1 − x)
(b) g(x) = −(x − 0.75)2
πx
(c) u(x) = sin( )
2
2
(d) v(x) = x + 2x
15. A farmer owns 50 papaya trees. Each tree produces 600 papayas in a year. For each additional
tree planted in the orchard, the output of each tree (including the pre-existing ones) drops by
5 papayas. How many trees should be added to the existing orchard in order to maximize the
total production of papayas?
16. Let a, b be numbers between 1 and 2 and let c, d be numbers between 3 and 4. Let u = a−1 , v =
b−1 , w = c−1 and x = d−1 . Say which of the following inequalities are true:
6
17. In the code fragment below, start and end are integer values and square(x) is a function that
returns True if x is a perfect square and False otherwise.
i := 0;
j := 0;
k := 0;
for m in [start,start+1, ...,end]{
if (square(m)=True){
i := i + m*m;
k := k + m*m;
}else{
j := j + m*2;
k := k + m*2;
}
}
At the end of the loop, which of the following are correct statements about the relationship
between i, j and k?
18. Given the following definition of the function foo, what does foo(1037,2) return? Note that
a//b denotes the quotient (integer part) of a ÷ b, for integers a and b. For instance 7//3 is 2.
function foo(n,d){
x := 0;
while (n >= 1) {
x := x+1;
n := n//d;
}
return(x);
}
7
19. A very special island is inhabited only by knights and knaves. Knights always tell the truth,
and knaves always lie. You meet three inhabitants: Ramesh, Bharat and Menaka. Ramesh
claims, “Bharat is a knave.” Bharat says, “Menaka and I are both knights or both knaves.”
Menaka claims that Bharat is a knave.
Which of the following are correct?
20. There are 7 switches on a switchboard, some of which are on and some of which are off. In
one move, you pick any 2 switches and toggle each of them—if the switch you pick is currently
off, you turn it on, if it is on, you turn it off. Your aim is to execute a sequence of moves and
turn all 7 switches on. For which of the following initial configurations is this possible? Each
configuration lists the initial positions of the 7 switches in sequence, from switch 1 to switch 7.
(a) (off,on,on,on,on,off,on)
(b) (off,on,on,on,off,on,off)
(c) (off,on,off,off,on,off,on)
(d) (off,on,off,off,off,on,off)
8
Part B
For questions in part (B), you have to write your answer with a short explanation in the space provided
below the question.
n For numerical answers, the following forms are acceptable: fractions, decimals,
n
symbolic e.g.: r , Pr , n! etc.
f : N × N 7→ N
2. Suppose A, B and C are m × m matrices. What does the following algorithm compute? (Here
A(i, j) denotes the (i.j)th entry of matrix A.)
for i = 1 to m
for j = 1 to m
for k = 1 to m
C(i, j) = A(i, k) ∗ B(k, j) + C(i, j)
end
end
end
1 1 0
3. Find A10 where A is the matrix 0 1 1 . Justify your answer.
0 0 1
4. In computing, a floating point operation (flop) is any one of the following operations performed
by a computer: addition, subtraction, multiplication, division. For example, the dot product of
two vectors (u, v, w) · (x, y, z) = ux + vy + wz involves 3 multiplications and 2 additions, a total
of 5 flops.
Calculate the exact number of flops required computing C = AB for two 5 × 5 matrices A and
X 5
B using a direct implementation of cij = aik bkj . How does this number change if both the
k=1
matrices are upper triangular?
5. A function f from the set A to itself is said to have a fixed point if f (i) = i for some i in A.
Suppose A is the set {a, b, c, d}. Find the number of bijective functions from the set A to itself
having no fixed point.
Description for the following three questions: Suppose X is the number of successes out
of n trials, where the trials are independent of each other. The probability of success of every
trial is p. The probability that there will be exactly k successes out of n trials is
n k
P(X = k) = p (1 − p)n−k , k = 0, 1, . . . , n.
k
9. For the situation in the previous problem, what is the expected number defaults?
10. Suppose the bank earns 10% of the loan amount for every loan that is repaid. If the person
defaults on his/her credit then the bank loses the entire loan amount. What is the expected
revenue of the bank from a loan of Rs. 100,000?
Description for the following four questions:
An ice-cream company mainly operates in the five southern states of India. The pie chart shows
the breakdown of revenues (in percentages) for the ice cream company over the last summer.
The bar chart shows the detail of breakdown for strawberry flavor by states in lakhs of rupees.
Lakhs of Rupees
Other
4% 20
12% 15
26%
Mint 10
Chocolate 16%
5
Chocolate Fudge
0
Tamil Nadu Kerala Karnataka Andhra Telengana
15. A square piece of paper ABCD of side length 1 is folded along the segment that connects the
upper right corner B and the midpoint Q of the left edge AD, as shown. What is the vertical
distance between the base edge (segment DC) and the point P (which was originally point A)?
A B
P
D C
16. A boolean value is a value from the set {True,False}. A 3-ary boolean function is a function
that takes three boolean values as input and produces a boolean value as output. Let f and g
be 3-ary boolean functions. We say that f and g are neighbours if f and g agree on at least one
input triple and disagree on at least one input triple: that is, there exists a triple (x, y, z) such
that f (x, y, z) = g(x, y, z) and a triple (x0 , y 0 , z 0 ) such that f (x0 , y 0 , z 0 ) 6= g(x0 , y 0 , z 0 ).
Suppose we fix a 3-ary boolean function h. How many neighbours does h have?
Description for the following four questions:
A golf club has m members with serial numbers 1, 2 . . . , m. If members with serial numbers i
and j are friends, then A(i, j) = A(j, i) = 1, otherwise A(i, j) = A(j, i) = 0. By convention,
A(i, i) = 0, i.e. a person is not considered a friend of himself or herself. Let Ak (i, j) refer to
the (i, j)th entry in the k th power of the matrix A.
Suppose it is given that A9 (i, j) > 0 for all pairs i, j where 1 ≤ i, j ≤ m, A2 (1, 2) > 0 and
A4 (1, 3) = 0. Then which of the following are necessarily true? Give reasons.
19. m ≤ 9.
20. m ≥ 6.
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination
15th May 2019
D − −
Enter your Admit Card Number :
IMPORTANT INSTRUCTIONS
• This booklet has 9 printed sheets, including this cover page. Sheet 2 (page 1) contains space to answer
part A, sheets 3 to 5 contain eighteen questions in part A and sheets 6 to 9 contain eighteen questions in
part B.
– For questions in part (A), you only have to write your answer on the designated page on the appro-
priate line. For example, if the answer is parts (a) and (c), write only (a) and (c) on the line and
if the answer is 2781, write this number on the line.
– For questions in part (B), you have to write your answer with short explanation in the space provided
below the question.
– For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr ,
n P , n! etc.
r
• Part A will be used for screening. Part B will be graded only if you score a certain minimum in part
A. However your scores in both parts will be used while making the final decision.
Points Remarks
Part A
Part B
Total
B1 B2 B3 B4 B5 B6 B7 B8 B9 Total
B10 B11 B12 B13 B14 B15 B16 B17 B18 Total
Part A - Answers
This is the only place that will be seen for grading part A. So carefully and clearly write the
answers to each question on the designated line below. Write only the final answers, do not show any
intermediate work. Illegible/unclear answers will not be considered.
A1. A10.
A2. A11.
A3. A12.
A4. A13.
A5. A14.
A6. A15.
A7. A16.
A8. A17.
A9. A18.
1
Notation
• A function f from a set A to a set B is said to be injective (or one-to-one) if f (x) = f (y)
implies x = y for all x, y ∈ A;
• f is said to be surjective (or onto) if for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all
y ∈ B and g(f (x)) = x for all x ∈ A and then g is said to be inverse of f and is denoted by
f −1 .
• For a matrix A, |A| denotes the determinant of A and AT denotes the transpose of A.
Part A - Questions
This section consists of some questions requiring a single answer and some multiple choice
questions. For questions that ask you to calculate a value, you will be assessed based on the
answer you provide. No explanation is required. In multiple choice questions, there may be
multiple correct choices. You have to select all the correct options and no incorrect option
to get full marks. There is no partial credit. Write the correct options / answer in the space
provided on page 1. Only page 1 will be seen for grading part A.
(a) 2n
(b) 2n − 1
(c) 2n − 2
(d) 2n/2
(a) (AT )T = A;
(b) |AT | = |A|;
(c) (AB)T = AT B T ;
(d) (A + B)T = AT + B T .
3
1 1 1 5 5 5 3 0 0
4. Let A = 0 2 2 , B = 0 10 10 , C = 3 6 0 . Which of the following state-
0 0 3 0 0 15 3 6 9
ments are true?
5. Consider the polynomials p(x) = (5x2 + 6x + 1)(x + 1)(2x + 3) and q(x) = (5x2 − 9x − 2)(2x2 +
5x + 3). The set of common divisors of p(x) and q(x) is:
(a) {2x + 3, x + 1, 5x + 1}
(b) {2x + 3, x − 1, 5x + 1}
(c) {x + 3, 2x + 1, x − 2}
(d) {2x − 3, x + 1, 5x + 1}
2x+1
6. Let R denote the set of real numbers and let A = {x ∈ R : x 6= 3}. For x ∈ A, let f (x) = x−3 .
Let B denote the range of f . Then
7. We need to choose a team of 11 from a pool of 15 players and also select a captain. The number
of different ways this can be done is:
(a) 15
11
(b) 11 · 15
11
(c) 15 · 14 · 13 · 12 · 11 · 10 · 9 · 8 · 7 · 6 · 5
(d) (15 · 14 · 13 · 12 · 11 · 10 · 9 · 8 · 7 · 6 · 5) · 11
8. Consider the following Venn diagram. The universal set U is the set of all natural numbers
from 1 to 1000.
4
A B
The sets A, B, C contain integers in U that are multiples of 6, 7, 8 respectively. The number of
elements in the shaded region is:
(a) 12
(b) 15
(c) 16
(d) 17
9. In the code fragment below, start and end are integer values and prime(x) is a function that
returns True if x is a prime number and False otherwise.
i = 0;
j = 0;
k = 0;
for m = start to end {
if prime(m) == True {
i = i + 1;
# Statement 1
}else{
j = j - 1 ;
# Statement 2
}
}
We wish to maintain the invariant k == i - j after each iteration of the for loop. What
should we insert at Statement 1 and Statement 2?
5
Description for the following two questions:
The following table gives the budget allocation (in Rupees Crores) to 5 different departments
and their quarterly expenditure for a particular year.
Department Allocation Q1 Q2 Q3 Q4
D1 240 25 60 70 45
D2 120 10 40 30 20
D3 200 30 40 60 20
D4 125 20 35 20 25
D5 180 40 20 60 30
10. As a percentage of total allocation, the maximum quarterly expenditure (in any quarter) was
shown by
(a) D2
(b) D5
(c) D1
(d) D3
11. Looking at the combined expenditure of all the five departments, which of the following gives
the correct order as far as expenditure in each quarter is concerned?
12. Three boxes are presented to you. At most one of them contains some gold. Each box has
printed on it a clue about its [Link] clues are:
Only one clue is true; the other two are false. Which box has the gold?
(a) Box 1
(b) Box 2
(c) Box 3
(d) None of them has the gold
13. Abha and Vibha both have white and yellow handkerchieves. To distinguish them, their mother
has marked Abha’s handkerchieves with the letter A and Vibha’s handkerchieves with the letter
V. There are 8 white handkerchieves of which 3 belong to Abha, and 11 yellow handkerchieves
6
of which 4 belong to Abha. All 19 handkerchieves were packed together in a bag for a trip.
Their mother pulled out a handkerchief from the bag without looking and found it was marked
V. What is the probability that the handkerchief was yellow?
(a) 5/12
(b) 7/19
(c) 7/12
(d) 11/19
14. We need to choose a team of 11 from a pool of 15 players and also select a captain. The number
of different ways this can be done is:
(a) 15
11
(b) 11 · 15
11
(c) 15 · 14 · 13 · 12 · 11 · 10 · 9 · 8 · 7 · 6 · 5
(d) (15 · 14 · 13 · 12 · 11 · 10 · 9 · 8 · 7 · 6 · 5) · 11
15. The sum of the diagonal elements of a matrix A is called the trace of A and is denoted by tr(A).
Which of the following statements about the trace are true?
16. An upper triangular matrix is a square matrix with all entries below the diagonal being zero.
Suppose A and B are upper triangular matrices. Which of the following statements are true?
7
Result Percentage of Students
Passed with distinction 2
Passed without distinction 82
obtain more that 80% marks in order to pass with distinction. The exam is taken by a group
of 225 students and the results are given in Table 1..
You may use the fact that the sample mean X̄ follows a Gaussian distribution with mean µ and
√
standard deviation σ/ n.
(a) The probability that the average score of the group of 225 students is less than 48 is 2%.
(b) The probability that the average score of the group of 225 students is less than 42.5 is
6.7%.
(c) The probability that the average score of the group of 225 students is greater than 49 is
more than 50%.
(d) The probability that the average score of the group of 225 students is greater than 57.5 is
more than 16%.
8
Part B
For questions in part (B), you have to write your answer with a short explanation in the space provided
below the question.
n For numerical answers, the following forms are acceptable: fractions, decimals,
n
symbolic e.g.: r , Pr , n! etc.
f (x) = k(x − x2 ), 0 ≤ x ≤ 1,
where k is the normalizing constant. Find the value of k and the expected value of the distri-
bution.
4. Four friends attending an opera leave their coats at the checkroom. When they return each one
is handed a coat that does not belong to her. In how many ways can this happen?
5. If the lines 2x + y = 2, −5x + 3y = 4 and ax + by = 1 are concurrent then prove that the line
9x − 10y = 1 passes through (a, b).
exp(x)
6. Let θ = loge (2). For −θ ≤ x ≤ θ, let f (x) = 1+exp(x) . Compute α and β where
7. Ani is training for the olympics with Usain Bolt. After a few days of training Usain challenges
Ani to catch him. Usain sets off running very slowly with a view to encourage Ani. He covers
70m the first minute, 100m the next minute, then 130m the minute afterwards and so on. Ani
is told to start 3 minutes later. Having trained hard he runs 100m the first minute, 150 m the
second Minute, then 200m and so on. Ani catches Usain at an integral multiple of a minute.
How many minutes did Ani run before catching up with Usain. What were their respective
speeds?
8. A small circular fire is spreading with its radius increasing at the rate of 1.5 metres per minute.
When the radius of the fire is 5 metres, how fast is the burned area growing?
9. Show that among any set of 7 distinct integers there must exist 2 integers whose sum or difference
is divisible by 10.
10. Let p(x) be a polynomial with integer coefficients. Let n be a positive integer and suppose a
and b are two integers such that a ≡ b(mod n). Is it true that p(a) ≡ p(b)(mod n)? Justify
your answer.
11. A thin piece of metal of length 20 cm and width 16 cm is to be used to construct an open-topped
box. A square will be cut from each corner and the sides will be folded up. What size corner
should be cut so that the volume of the box is maximized?
12. Let n, k be positive integers. The expansion of (x1 + · · · + xk )n is given by
X n!
(x1 + · · · + xk )n = xn1 xn2 . . . xnk k ,
n1 !n2 ! . . . nk ! 1 2
where the sum is taken over all sequences n1 , n2 , . . . , nk of non-negative integers such that
n1 + n2 + · · · + nk = n. What is the coefficient of x5 in the expansion of (1 + 3x + 2x2 )4 ?
14. A thief picks a wallet and starts running at a speed of 5 m/s with zero acceleration. In 5
seconds, a policewoman notices the alarm and starts following the thief with a speed of 3 m/s
with a uniform acceleration of 1 m/s2 . How many seconds will it take the policewoman to catch
the thief, assuming she follows the same path as that of the thief? (A body moving with initial
velocity v0 m/s and uniform acceleration a m/s2 will cover a distance of (at2 /2 + v0 t) meters
in t seconds.)
15. Consider the following pseudocode for a function that operates on an N element array
A[1], A[2], . . . , A[N ] of integers.
(a) Explain what effect the function has on the input array A.
(b) If N = 100, how many times is the comparison A[i] < A[position] checked?
17. If the proportion of grey cars sold in Delhi is the same as the proportion of red cars sold in
Delhi, how many red cars were sold in Delhi?
18. 12% of all cars were sold in Chennai. What is the largest possible percentage of brown cars sold
in Chennai, rounded off to the nearest integer?
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination
4th October 2020
D − −
Enter your Admit Card Number :
IMPORTANT INSTRUCTIONS
• This booklet has 11 printed sheets, including this cover page. Sheet 2 (page 1) contains space to answer
part A, sheets 3 to 6 contain twenty questions in part A and sheets 7 to 11 contain twenty questions in
part B.
– For questions in part (A), you only have to write your answer on the designated page on the appro-
priate line. For example, if the answer is parts (a) and (c), write only (a) and (c) on the line and
if the answer is 2781, write this number on the line.
– For questions in part (B), you have to write your answer with short explanation in the space provided
below the question.
– For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr ,
n P , n! etc.
r
• Time allowed is 3 hours. Total points: 100 = 40 for part A + 60 for part B.
• Part A will be used for screening. Part B will be graded only if you score a certain minimum in part
A. However your scores in both parts will be used while making the final decision.
Points Remarks
Part A
Part B
Total
B1 B2 B3 B4 B5 B6 B7 B8 B9 B10 Total
B11 B12 B13 B14 B15 B16 B17 B18 B19 B20 Total
This page intentionally left blank.
Part A - Answers
This is the only place that will be seen for grading part A. So carefully and clearly write the answers to
each question on the designated line below. Write only the final answers, do not show any intermediate work.
Illegible/unclear answers will not be considered.
A1. A11.
A2. A12.
A3. A13.
A4. A14.
A5. A15.
A6. A16.
A7. A17.
A8. A18.
A9. A19.
A10. A20.
1
This page intentionally left blank.
Notation
• A function f from a set A to a set B is said to be injective (or one-to-one) if f (x) = f (y) implies
x = y for all x, y ∈ A;
• f is said to be surjective (or onto) if for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all y ∈ B
and g(f (x)) = x for all x ∈ A and then g is said to be inverse of f and is denoted by f −1 .
• For a matrix A, |A| denotes the determinant of A and AT denotes the transpose of A.
Part A - Questions
This section consists of some questions requiring a single answer and some multiple choice questions.
For questions that ask you to calculate a value, you will be assessed based on the answer you provide.
No explanation is required. In multiple choice questions, there may be multiple correct choices. You
have to select all the correct options and no incorrect option to get full marks. There is no partial credit.
Write the correct options / answer in the space provided on page 1. Only page 1 will be seen for grading
part A.
f(x, y)
{
if (y != 0)
return (x * f(x, y-1));
else
return 1;
}
What is f(6,3)?
(a) 243
(b) 729
(c) 125
(d) 216
3
2. Consider the matrices
0 0 0 0 15 5 4 3 2 1
0 0 0 13 14
9 8 7 6 0
A=
0 0 10 11 12
and B=
12 11 10 0 0 .
0 6 7 8 9 14 13 0 0 0
1 2 3 4 5 15 0 0 0 0
3. Consider the following program. Assume that all variables are integers. Note that x%y computes the
remainder after dividing x by y. The division is an integer division. For example, 1/3 will return zero
while 10/3 will return 3.
g(n)
{
result = 0;
i = 1;
repeat until (n == 0)
{
remainder = n%2;
n = n / 2;
result = result + (remainder * i);
i = i * 10;
}
return result;
}
What is g(25)?
(a) 11001
(b) 10011
(c) 11011
(d) 10101
4
4. Which of the following limits are correct?
x2 + 2x
(a) lim =1
x→0 2x
2x2 + x − 1 3
(b) lim =
x→1/2 2x − 1 2
(c) lim 18x3 − 12x2 + 1 = ∞
x→∞
(d) lim 18x3 − 12x2 + 1 = −∞
x→−∞
5. As per the data released by the US Department of Health, Education and Welfare, the number of Ph.D.
degrees conferred in Earth Sciences from the year 1948 to 1954 is as given in Table 5.
Year Degrees
1948 57
1949 88
1950 125
1951 135
1952 126
1953 146
1954 141
Based on the average of all available three year moving averages of annual growth rate, and the number
of degrees in 1954, what will be the (approximate) predicted number of degrees in earth sciences in 2020?
Note that a moving average or a rolling average is an average of a subset of data points. Choose the best
answer.
(a) 900
(b) 9,000
(c) 9,00,000
(d) 90,00,000
6. Suppose that A is an n × n matrix with n = 10 and b is an n × 1 vector. Suppose that the equation
Ax = b for an n × 1 vector does not admit any solution. Which of the following conclusions can be drawn
from the given information?
5
7. Consider the following bar chart:
(a) Number of students who scored A in Algebra is higher than the number of students who scored A
in Calculus.
(b) Percentage of students who scored A or B in algebra is lower than the percentage of students who
scored A or B in calculus.
(c) Calculus is easier than algebra.
(d) Considering this data, the average percentage of students scoring A is 12%.
8. Let A = ((aij )) be a 7 × 7 matrix with ai,i+1 = 1 for 1 ≤ i ≤ 6, a7,1 = 1 and all the other elements of the
matrix are zero. Which of the following statements are true?
(a) |A| = 1
(b) trace(A) = 0
(c) A−1 = A
(d) A7 = I, where I is the identity matrix
9. Let A and B be events such that P (A) = 0.4, P (B) = 0.5 and P (A ∪ B) = 0.7. Which of the following
are true? (For sets A, B, A∆B = (Ac ∩ B) ∪ (A ∩ B c )).
6
Description for the following 2 questions:
The lifespan of a battery in a car follows Gamma distribution with probability density function
β α −βx α−1
f (x) = e x , 0 < x < ∞,
Γ(α)
where α > 0 and β > 0 . The mean and variance of a Gamma distribution are E(X) = αβ and V(X) = βα2
respectively. From historical data the mean and variance of the lifespan of a battery are estimated as 4
years and 2 years respectively.
(a) α = 16 and β = 4
(b) α = 8 and β = 2
(c) E(X 2 ) = αβ ( 1+α
β )
(d) E(X 2 ) = 18
11. Out of a large number of cars produced by the automaker, the percentage of batteries that will last for
more than 8 years is
(a) "Z #
8
β α −βx α−1
e x dx × 100%.
0 Γ(α)
(b) " #
8
β α −βx α−1
Z
1− e x dx × 100%.
0 Γ(α)
(c) "Z #
∞
xβ α −βx α−1
e x dx × 100%.
8 Γ(α)
(d) "Z #
8
xβ α −βx α−1
e x dx × 100%.
0 Γ(α)
(a) 49
(b) 204
(c) 203
(d) 140
7
13. It is mid-semester exam week at CMI and first-year students from both [Link]. Data Science (DS) and
[Link]. Computer Science (CS) have their exams scheduled for Monday from 10 a.m. to 1 p.m. in Lecture
Hall 1. The first row in Lecture Hall 1 has six seats. In how many different ways can three [Link]. DS
students - Anish, Binish and Finish - and three [Link]. CS students - Ramesh, Suresh, and Ragesh - be
seated in this row, in such a way that two students from the same course do not sit next to each other?
(a) 36
(b) 48
(c) 72
(d) 96
14. Suppose you roll two six-sided fair dice with faces numbered from 1 to 6 and take the sum of the two
numbers that turn up. What is the probability that:
15. Let f (x) be a real-valued function all of whose derivatives exist. Recall that a point x0 in the domain is
called an inflection point of f (x) if the second derivative f 00 (x) changes sign at x0 . Given the function
x5 x4
f (x) = − + 3x + 1, which of the following statements are true?
20 2
(a) x0 = 0 is not an inflection point.
(b) x0 = 6 is the only inflection point.
(c) x0 = 0 and x0 = 6, both are inflection points.
(d) The function does not have an inflection point.
8
17. The identity
∞
1 X
= (2r)k
(1 − 2r)
k=0
is true
1
(a) if and only if r 6= 2
1
(b) if and only if 0 ≤ r < 2
(c) if and only if − 21 ≤ r < 1
2
(d) if and only if − 21 < r < 1
2
18. The sum and product of the roots of the polynomial 9x2 + 171x − 81 are, respectively:
19. Choose the conclusions that follow logically from the statements given below.
i Nobody who really appreciates [Link] fails to subscribe to his YouTube channel.
ii Owls are hopelessly ignorant of music.
iii No one who is hopelessly ignorant of music ever subscribes to [Link]’s YouTube channel.
(a) Anyone who subscribes to [Link]’s YouTube channel is hopelessly ignorant of music.
(b) Owls don’t really appreciate [Link].
(c) Owls are not really appreciated by [Link].
(d) Anyone who really appreciates [Link] is not hopelessly ignorant of music.
(a) ex ≥ (1 + x) for x ≥ 0
(b) ex ≤ (1 + x) for x < 0
(c) ln(x) < (1 + x) for x > 0
(d) ex < x2 for all real numbers x
9
This page intentionally left blank.
Part B
For questions in part (B), you have to write your answer with a short explanation in the space provided below
the question. For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr ,
n P , n! etc.
r
1. For any string str, length(str) returns the length of the string, append(str1,str2) concatenates str1
with another string str2, and trim(str) removes any spaces that exist at the end of the string str. The
function reverse(str, i, j) reverses the part of the string from position i to position j. Assume that
position 0 refers to the first character in the string. What does the following pseudo-code do?
trim(str);
return str;
}
0 −1
2. Consider the matrix A = . Find An , in terms of n, for n ≥ 2.
1 0
11
3. The following graph shows the performance of students in an exam. The marks scored by every student
are a multiple of five. The j th -percentile u∗ for a discrete data x1 , x2 , . . . , xn is defined as follows. Let
j·n
x(1) , x(2) , . . . , x(n) be the ordering of the data in ascending order. Let t = 100 and let k be an integer such
that k ≤ t < (k + 1) and let s = t − k. Then u∗ = x(k) + s ∗ (x(k+1) − x(k) ). Here, x(n+1) is defined to be
x(n) .
Based on the information presented in the graph, answer the following questions.
4. In the figure shown below, the circle has diameter 5. Moreover, AB is parallel to DE. If DE = 3 and AB
= 6, what is the area of triangle ABC?
12
The following description holds for the two problems below.
A permutation σ is a bijection from the set [n] = {1, 2, . . . , n} to itself. We denote it using the notation
1 2 ... n
,
σ(1) σ(2) . . . σ(n)
1 2 3
e.g. if n = 3 then denotes the permutation defined by σ(1) = 2, σ(2) = 3 and σ(3) = 1.
2 3 1
An inversion in σ is a pair (i, j) such that i < j but σ(i) > σ(j). The sign of a permutation σ (denoted
sgn(σ)) is defined to be (−1)inv(σ) , where inv(σ) denotes the total number of inversions in σ. In the above
example, there are 2 inversions corresponding to the pairs (1, 3) and (2, 3) so that sgn(σ) = (−1)2 = 1.
For each permutation σ, define a matrix Aσ as follows:
(
1 if σ(i) = j
Aσ (i, j) =
0 otherwise
6. What are the determinants |Aσ | and |Aτ |? Can you relate these with the signs of permutations σ and τ ?
13
7. The case fatality rate (CFR) of a disease is the ratio of the number of deaths from the disease to the
total number of people diagnosed with the disease (“patients”), and is usually expressed as a percentage.
It has been reported that the CFR of Pandemic-20 among elderly people in Gondwanaland is 20%. One
way of treating a Pandemic-20 patient involves putting the patient on a ventilator. It has been observed
that in Gondwanaland, 60% of the elderly Pandemic-20 patients who survived the disease had been put
on a ventilator, and 10% of the elderly Pandemic-20 patients who died from the disease had been put on
a ventilator. What is the probability that an elderly Pandemic-20 patient in Gondwanaland survives the
disease if they were put on a ventilator as part of the treatment?
8. Owing to a defect in a certain machine which makes N95 masks, there is a 0.1% probability that a mask
it makes is not effective in preventing airborne viruses from being inhaled.
(a) What is the probability that the first 1000 masks that the machine produces are effective? (You may
leave your solutions as arithmetic expressions; there is no need to compute their decimal representa-
tions.)
(b) What is the probability that among the first one crore (107 ) masks that the machine produces, there
is at least one mask which is not effective?
14
9. The International Chess Federation is organizing an online chess tournament in which 20 of the world’s top
players will take part. Each player will play exactly one game against each other player. The tournament
is spread over three weeks; it starts at 9 a.m. on the Monday of Week 1 and ends at 6 p.m. on the Friday
of Week 3. Note that before 9 a.m. on the Monday of Week 1 every player would have completed the
same number of games in the tournament; namely, zero. Also, after 6 p.m. on Friday in Week 3, every
player would have completed the same number of games in the tournament, namely, nineteen.
Prove that at any point in time between 9 a.m. on the Monday of Week 1 and 6 p.m. on the Friday
of Week 3, there are at least two players who would have completed the same number of games in the
tournament till that point.
10. Your class has a textbook and a final exam. Let P, Q and R be the following propositions:
• P : You get an A on the final exam.
• Q: You do every exercise in the book.
• R: You get an A in the class.
Translate the following assertions into propositional formulas using P, Q, R and the propositional connec-
tives ∧ (and ), ∨ (or ), ¬ (not) and ⇒ (implies).
(a) To get an A in the class, it is necessary for you to get an A on the final.
(b) You get an A on the final, but you don’t do every exercise in this book; nevertheless, you get an A
in this class.
15
11. Two friends Amar and Prem wish to meet at a theme party between 5 p.m. and 6 p.m. (They are said
to meet if they are in the room at the same time or if one of them leaves as the other enters.) Once they
enter, they stay for exactly 20 minutes.
12. Let f be a continuous function on the closed interval [a, b] and differentiable on the open interval (a, b),
where a < b. It is known that there exists c in (a, b) such that
f (b) − f (a)
f 0 (c) = .
b−a
13. Let R be the set of all binary relations on the set {1, 2, 3}. Suppose a relation is chosen from R at random.
What is the probability that the chosen relation is symmetric?
16
14. Peppa and her friends Suzy and Emily are making 3 masks: a knight mask, a pirate mask and an elf
mask. The one wearing the knight mask must always tell the truth, the one wearing the pirate mask
must always lie and the one wearing the elf mask could sometimes lie and sometimes tell the truth. After
making three masks, one of each kind, they all wear one each and make the following statements:
15. For the function f (x) = ln(x)/x, show that the maximum value of f (x) occurs when x = e. Use this to
show that xe < ex for all positive values of x.
16. Given the set of letters {a,b,c,d,e,f,g,h,i,j,k,l,m}, we can list out all permutations of these let-
ters in lexicographic (dictionary) order. The first three permutations in this list are abcdefghijklm,
abcdefghijkml and abcdefghijlkm and the last one is mlkjihgfedcba. What permutations would ap-
pear immediately before and after the following one in this lexicographically ordered list of permutations?
bcjameflkihgd
17
17. Consider the following code, where A is an array of integers of size size(A) with values A[0] to A[size(A)-1],
and reverse(A,i,j) reverses the segment A[i] to A[j] if i <= j and has no effect otherwise. For in-
stance, if A = [0,1,2,3,4,5], then reverse(A,2,4) would modify A to [0,1,4,3,2,5].
def mystery(A){
for j in [0,1,..,size(A)-1] {
p = j;
for i in [j,j+1,..,size(A)-1] {
if A[i] > A[p] {
p = i;
}
reverse(A,j,p);
}
}
}
(b) Suppose size(A) is 1000. How many times is the test A[i] > A[p] executed?
18. Eight students are to be seated around a circular table in a circular room. Two seatings are regarded as
defining the same arrangement if each student has the same student on his or her right in both seatings:
it does not matter which way they face. How many arrangements of these 8 students are there with 2
chosen students, say student A and student B, always sitting together?
18
19. Let f be a continuous bijection from closed unit interval [0, 1] onto itself. (Recall the Intermediate Value
Theorem: let f be a real valued continuous function on an interval [a, b]. Let c, d ∈ [a, b] be such that
f (c) < f (d) and let α ∈ (f (c), f (d)) be an intermediate value. Then there exists y ∈ [a, b] such that
f (y) = α.)
(iv) Give an example of such a function wherein the fixed point is unique and an example of a function
with more than one fixed point.
19
20. A multi-national conglomerate sells soap products for five different market segments, namely (i) Women,
(ii) Men, (iii) Kids, (iv) Sports, and (v) Luxury. The sales of these five segments (in lakh number of
packs) during 2012 and 2017 are shown in the following figure.
(a) By what percentage were the sales of the Women segment in 2017 more than the sales of the Men
segment in 2017?
(b) During the period 2012-2017, which segment experienced the minimum rate of increase in sales?
20
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination
1st August 2021
D − −
Enter your Admit Card Number :
IMPORTANT INSTRUCTIONS
• Part (A) consists of multiple-choice questions. There may be multiple correct choices. You have to select all
the correct options and no incorrect option to get full marks. There is no partial credit.
• For questions in part (A), you have to provide the answers on the computer. You only have to choose the
appropriate answer(s) from the choices provided. If the answer is parts (a) and (c), choose only (a) and (c).
• For questions in part (B), you have to write your answer with a short explanation in the space provided for
the question.
• Part(A) will be used for screening. Part (B) will be graded only if you score a certain minimum in part
(A). However, your scores in both parts will be used while making the final decision.
• For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr , n Pr , n!.
• f is said to be surjective (or onto) for every y ∈ B there exists x ∈ A such that f (x) = y.
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all y ∈ B and
g(f (x)) = x for all x ∈ A.
• For a matrix A, AT denotes the transpose of A. For a square matrix A, |A| denotes the determinant of A
and trace(A) denotes the trace of A — namely the sum of the diagonal elements of A.
• A diagonal matrix is a square matrix D with all off-diagonal entries equal to zero, i.e., dij = 0 for all i 6= j.
• An upper triangular matrix is a square matrix A for which all entries below the diagonal are zero, i.e., aij = 0
for i > j.
• A symmetric matrix is a square matrix S for which sij = sji for all i 6= j.
1
Part A - Multiple-choice questions
For questions in part (A), you have to provide the answers on the computer. Choose only the appropriate answer(s)
from the choices provided. If the answer is parts (a) and (c), choose only (a) and (c). There is no partial credit.
1. There are two longest subsequences, not necessarily contiguous, common to the strings “ARTIFICIAL” and
“INTELLIGENCE”. They are “IIC” and “TIC” which are of length three.
Consider two strings S1 = “CORONAVIRUS” and S2 = “SARSCOVID”. Let x be the length of a longest
common subsequence between S1 and S2 and let y be the number of such longest common subsequences of
length x between S1 and S2. What is x + 5y?
(a) 13
(b) 15
(c) 14
(d) 16
(a) 1, − 1, 2, 2 + 3i
(b) 1 + i, 1 − i, 2, − 2
(c) 1, − 1 + i, 2, 2 + 3i
(d) 1 + i, − 1 + i, 2, − 2
(a) 23
(b) 17
(c) -17
(d) 35
2
4. A student has an average score of 80 from her first four Mathematics tests, and 88 from her first five Physics
tests. How much must she score in her upcoming tests to raise her average score in Mathematics and Physics
to 82 and 89, respectively?
5. A binary tree starts with a single root node at the top of the tree. Each node can have either a left child or
a right child, or both, or neither. The children of a node are drawn below it, connected by edges. Here are
the five possible binary trees with three nodes.
Note that the directions left and right of the children matter. In the second tree, the root has a left child
that has a left child, while, in the fourth tree, the root has a left child that has a right child, and so on.
How many different binary trees can be constructed with four nodes?
(a) 13
(b) 15
(c) 14
(d) 30
3
6. Consider the following code, in which A is an array indexed from 0.
function foo (A , n ) {
x = 0;
for i = 0 to n -1 {
x = A [ i ]^ x ;
}
return ( x );
}
Here, a^b represents the bitwise Exclusive OR function over variables a and b.
Given integers a and b, we write them in binary, padded by zeros to the left to make them of equal length.
We then apply Exclusive OR to these binary representations bitwise. The operation a^b denotes the in-
teger value obtained by performing bitwise Exclusive OR on the binary values of a and b. For example,
3^4 = 011^100 = 111 = 7, and 9^5 = 1001^0101 = 1100 = 12. The truth table for the Exclusive OR
function is provided below.
a b a^b
0 0 0
0 1 1
1 0 1
1 1 0
(a) 0
(b) 2
(c) 3
(d) 7
7. Fifteen telephones are received at a service center. Of these, 5 are mobile, 6 are cordless, and 4 are wired.
These 15 phones are randomly numbered from 1 to 15 to establish the order in which they are serviced.
Which of the following statement(s) is/are correct?
(a) The probability that among the first 3 serviced, the first and third are mobile and the second is not, is
5 × 10 × 4
.
15 × 14 × 13
1
(b) The probability that the first four serviced are all the wired phones, is 15 .
4
(c) The probability
that after servicing ten of these phones, only one of the three types remain to be
6
5
serviced, is 15 .
5
5 6 4
2 + 2 + 2
(d) The probability that two phones of each type are among the first six serviced, is 15
.
6
4
8. Which of the following statement(s) is/are true?
x1 + x2 + · · · + x2k 1
(a) For k = 69597 and x1 , x2 , . . . , xk ∈ (0, ∞), k
≤ (x1 x2 · · · x2k ) 2k .
2
(b) For any three real numbers x, y, z, |x − z| ≤ |x − y| + |y − z|.
∞
X 37
(c) For |r| < 1, 37 · rn = .
1−r
n=0
(d) (n3 − n) is divisible by 3 for all positive integers n.
10. Let A, B be n × n matrices. Which of the following properties of A and B is/are preserved under matrix
multiplication?
5
11. The proportion of visitors to an e-commerce website in a week who would purchase a product follows the
beta distribution with the probability density function
Γ(α + β) α−1
f (x) = x (1 − x)β−1 for 0 < x < 1,
Γ(α)Γ(β)
where Γ is the gamma function, α > 0, β > 0 and (α + β) > 2. The mean and mode of the beta distribution
α α−1
are E(X) = α+β and Mode(X) = α+β−2 . From historical data the mean and mode of the proportion of
1 1
buyers are estimated as 4 and 5 respectively. Which of the following statement(s) is/are correct?
(a) α = 3 and β = 9.
(b) The probability that in a given week the proportion of visitors who buy the product is between 10%
and 20% is given by
Z 0.2 Z 0.1
Γ(α + β)
xα−1 (1 − x)β−1 dx − xα−1 (1 − x)β−1 dx .
Γ(α)Γ(β) 0 0
(d) The probability that in a given week the proportion of visitors who buy the product is less than 20%
is given by Z 1
Γ(α + β) α
1− x (1 − x)β dx.
0.2 Γ(α)Γ(β)
12. There are 1010 functions from {1, 2, . . . , 10} to {1, 2, . . . , 10}. Pick one such function f at random. Let p1
be the probability that f −1 (3) has exactly four elements, and p2 the probability that f −1 (2) has exactly six
elements. Which of the following statement(s) is/are true?
(a) p1 > p2
(b) p1 < p2
(c) p1 = p2
(d) p1 = 34 p2
a 1 0
13. For a non-zero real number a, the inverse of J = 0 a 1 is
0 0 a
−1 −2 −3
a a a
(a) 0 a−1 a−2
0 0 a−1
−1
−a−2 a−3
a
(b) 0 a−1 −a−2
0 0 a−1
−1
a 1 0
(c) 0 a−1 1
0 0 a −1
−1 −2
a a 0
(d) 0 a−1 a−2
0 0 a−1
6
Description for following two questions: In the 2019-2020 season of the English Premier League (EPL),
380 matches were played in a home and away format. The figure below describes the number of goals scored
by the home team and the away team against the number of matches played. For example, the home team
scored one goal in 125 matches.
(a) (b)
(a) The average number of goals scored by the home team over 380 matches is less than 1.5, and for away
teams are less than 1.
(b) In the whole season of the EPL, a total of 1034 goals were scored.
(c) The probability that away team failed to score any goal is 22.11%.
(d) The probability that home team scored more than 3 goals is 6.6%.
(a) In more than 50% matches, the home team scored at most one goal.
(b) In more than 10% matches, the away team scored more than two goals.
(c) In more than 15% matches, the home team scored three or more goals.
(d) In more than 90% matches, the away team scored less than three goals.
16. You are given a sequence of N digits. From this you can generate N -digit numbers as follows: pick up each
digit in the given order, starting from the first one. Place it either to the left or to the right of the number
you have generated so far. For instance, if you start with the sequence [4, 3, 2, 5, 2], you can generate 53422
through the steps 4 → 34 → 342 → 5342 → 53422, and 22345 through the steps 4 → 34 → 234 → 2345 →
22345.
Which of the following sequences could have generated 51324?
(a) [2, 1, 3, 4, 5]
(b) [2, 3, 1, 5, 4]
(c) [2, 3, 4, 1, 5]
(d) [2, 4, 1, 3, 5]
7
17. Which of the following is/are true?
1 1 1 1
(a) 2 2 < 3 3 and 3 3 > 4 4 .
(b) 2r−1 r! ≥ (2r − 2)! for all natural numbers r.
(c) sin(2x) ≥ cos(x) for all values of x in π6 , π2 .
A11 A12
18. Let A11 , A12 , A21 , A22 , B11 , B12 , B21 , B22 be n×n matrices. Consider the 2n×2n matrices A =
A21 A22
B11 B12
and B = . The product AB is given by:
B21 B22
A11 B11 A12 B12
(a)
A21 B21 A22 B22
A11 B21 + A12 B11 A11 B22 + A12 B21
(b)
A21 B21 + A22 B11 A21 B22 + A22 B21
A11 (B11 + B21 ) A12 (B12 + B22 )
(c)
A21 (B11 + B21 ) A22 (B12 + B22 )
A11 B11 + A12 B21 A11 B12 + A12 B22
(d)
A21 B11 + A22 B21 A21 B12 + A22 B22
19. Consider right angled triangles with integer side lengths a, b, c where c is the hypotenuse. Call a right angled
triangle special if a and b are odd integers. How many special right angled triangles exist?
(a) 23
(b) infinitely many
(c) 0
(d) 12
20. Given a sequence of numbers [x1 , x2 , . . . , xn ], we say that xi is left-visible if each number in [x1 , x2 , . . . , xi−1 ]
is strictly smaller than xi . Similarly xi is right-visible if each number in [xi+1 , xi+2 , . . . , xn ] is strictly smaller
than xi . For instance, in the sequence [13, 37, 24, 55, 46], the numbers 13, 37, 55 are left-visible and 55, 46
are right-visible.
Suppose we construct a sequence from the set {17, 22, 38, 49, 53} such that 4 numbers are left-visible and 2
numbers are right-visible. In addition, we are told that 22 is at the second position from the left. What are
the possible numbers at the third and fifth positions?
8
Part (B) - Short-answer questions
For questions in part (B), you have to write your answer with a short explanation in the space provided for the
question in your answer sheet. If you need more space, you may continue on the pages provided for rough work.
Any such overflows must be clearly labeled.
x = answer ;
answer = ( answer * 10) + 1;
while ( x > 0) {
y = x % 10;
answer = ( answer * 10) + y ;
x = x // 10;
}
return ( answer );
}
Here,
2. Food delivery agents Aman, Boni, Chan, Dong and Eman were assessed on five parameters P1 to P5. They
received an integer rating between 1 and 5 for each parameter. None of them received the same rating in
four or more parameters. Everyone received a score of 1 in P2 or P5. All of them received the same rating
in at least two parameters. The partial information related to the ratings are given in the table below.
Name P1 P2 P3 P4 P5
Aman 3
Boni 4
Chan 5
Dong 2
Eman 1
(a) What is the maximum average rating Boni could have achieved across all the five parameters?
(b) What is the minimum average rating Chan could have received across all the five parameters?
9
3. Consider the following code where A is an array indexed from 0.
function foo (A , year , n ) {
l = 0 , r = n - 1 , c = 0;
while ( l <= r ) {
c = c + 1;
m = l + ( r - l ) // 2;
if ( A [ m ] == year ) {
return ( c * m );
}
if ( A [ m ] < year ) {
l = m + 1;
} else {
r = m - 1;
}
}
return ( -1);
}
function bar () {
A = [2016 , 2017 , 2018 , 2019 , 2020 , 2021 , 2022];
result = foo (A , 2021 , 7);
print ( result );
}
Here, a // b represents integer division. For example, 23 // 10 = 2. What will be printed when bar() is
executed?
4. The CMI MSc DS 2021 batch of 60 students is holding an online event to celebrate their joining CMI. Student
Aruni is in charge of organizing the musical section, and she sends out an online form where each student has
to mark whether they agree or decline to performing two activities during the event: singing, and playing a
musical instrument. Each student can mark one of four sets of choices: (i) agree to both singing and playing
an instrument, (ii) agree to sing and decline to play an instrument, (iii) agree to play an instrument and
decline to sing, or (iv) decline to do either activity.
All the students respond within the deadline, and Aruni sits down to tabulate the results so that she can
plan the musical events. She finds that thirty five students agreed to sing or play an instrument, of whom
twenty students agreed to do both.
How many students agreed to do exactly one activity, and how many declined to participate?
5. Show that every selection of 503 numbers from {1, 2, 3, . . . , 987} has two numbers with g.c.d. 1. Recall that
the g.c.d. of two positive integers x, y is the largest positive integer smaller than x, y which divides both x
and y.
10
6. Let S be the sphere given by the equation x2 + y 2 + z 2 − 6x + 4y − 4z − 272 = 0. What are the centre and
radius of S? What is the minimum distance between S and the plane 2x + 2y + z = 214?
7. We draw two rows of n points with labels {1, 2, . . . , n}, as shown in the figure below.
1 2 3 n
1 2 3 n
We connect each point on the top with a point on the bottom at random, making sure that no two points
on the top are connected to the same point on the bottom. We say point j on the top is special if it gets
connected to point j below.
Let X be the number of special points. What is E(X), the expected value of X?
8. Let Tn denote the set of all sequences over {0, 1, 2} of length n. If we pick an element x in Tn uniformly at
random what is the expected number of 1’s in x?
n
X 1
9. What is the smallest possible value of , if the di ’s are constrained to be non-negative real numbers
di + 1
i=1
n
X
and satisfy di = N .
i=1
a b c
10. Let A be the 3 × 3 real matrix d e f . Suppose xT Ax ≥ 0 for every x ∈ R3 . Then show that all of a, e
g h i
and i are non-negative.
11. In the finale of the Indian Idol programme, Ladies Special, there are four women contestants — Arunima,
Priyamani, Razi and Shriya. The organisers send all participants a list of 7 songs, asking each one to pick
one song for the finale. All the four girls pick the same song, Pyar Hua Chupkese from the film 1942 A Love
Story. To resolve the tie, two days before the finale, the organisers prepare 7 sheets of paper and fold them.
Exactly one of the 7 songs from the list is written on each folded sheet and the folded sheets are identical
in all other aspects. First Arunima is asked to pick one sheet out of 7, then Priyamani is asked to pick one
sheet out of the remaining 6, then Razi is asked to pick one out of the remaining 5 and finally Shriya is asked
to pick one out of the remaining 4.
(a) What is the probability that the sheet chosen by Razi has the song Pyar Hua Chupkese?
(b) When Shriya is asked to choose a sheet, she argues that the three sheets chosen by the others should
be opened, and if Pyar Hua Chupkese is not chosen by anyone, she should be allowed to pick that song.
This is agreed to. What is the probability that Shriya gets to sing the song Pyar Hua Chupkese?
11
Description for following two questions: A Non-Banking Finance Corporation (NBFC) declares fixed
annual rates of simple interest on their auto and housing loans each year. The rates of interest offered by
the company differ from year to year depending on the variation in macro economic indicators like inflation,
RBI’s repo rate etc. The annual rates of interest offered by the company for the Auto and Housing sectors
over the years are shown in the figure.
12. In 2013, a customer took a housing loan and a car loan. The total loan amount was |60 lakhs. The interest
paid by the customer after one year was |7.36 lakhs. What was the housing loan amount?
13. In 2012, Customer A took a fixed interest auto loan of |5 lakh for 4 years, which meant he paid interest
according to the 2012 rate each year. Also in 2012, Customer B took a variable interest auto loan for |5
lakh for 4 years which meant his interest each year was calculated based on the prevailing interest rate for
that year. Which of them paid more interest over 4 years? How much more?
14. Let Y be a continuous random variable that takes values in [0, 1].
Determine c.
(b) Using g(y), find the probability that Y is greater than 0.8.
12
15. The state government has decided to regulate the sale and distribution of solar power. There are multiple
suppliers and consumers, as described in the tables below. The supplier table lists the amount of electricity
generated by each supplier, in megawatts (MW), and the supplier’s selling price per MW. The consumer
table lists the amount of electricity required by each consumer, in MW, and the price the consumer will pay
per MW.
The government wishes to fix a uniform market price per MW for solar power. If this price is p, any seller
whose selling price is at most p will be willing to sell some or all of the electricity they generate at price p.
Similarly, any consumer who is willing to pay at least p can buy as much electricity as they need at price p,
upto their required quantity.
Find the value of p at which the maximum amount of solar power can be bought and sold on the market.
16. (a) If a polynomial f (x) has roots r1 , r2 , . . . rn , what are the roots of the polynomial f (x + 1)?
(b) Let f be a polynomial of degree three. Set g(x) = f (x − 1). Assume that −1 is not a root of f . What
are the roots of the polynomial x3 g(1/x)?
ln x
18. (a) Consider the function f (x) = x . Find the critical point(s) of f and say whether f has a maximum or
minimum at that point.
(b) Prove that for integers a > b ≥ 3, we must have ab < ba .
19. Recall that if h is a function from X to Y and g is a function from Y to Z then, g ◦ h is the function from
X to Z such that (g ◦ h)(x) = g(h(x)), for all x ∈ X.
Let S be the set of all functions f from {1, 2, 3, 4, 5, 6} to {1, 2, 3, 4, 5, 6} such that f ◦ f = f .
(a) Compute the number of functions f ∈ S whose range has three elements.
(b) What is the cardinality of S?
13
20. A pinhole camera is placed between an object and a sensor. Recall that images from a pinhole camera are
inverted (see figure below). Assume that the object lies on a plane. Also assume that the plane containing
the object, the plane containing the pinhole and the sensor plane are all parallel to each other.
¥¥É÷÷
Sensor
plane
I
pinhole
1¥
1,
(a) Show that straight lines are projected to straight lines. In particular, show that if A, B, C are three
collinear points on an object, then their corresponding images a, b, c are also collinear.
(b) Suppose two identical objects M and N having height 60cm are placed before the pinhole camera at
distances 90cm and 120cm respectively. Suppose also that the distance between the pinhole and the
sensor plane is 30cm. What are the heights of their images after projection through the pinhole camera?
14
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Program in Data Science
Entrance Examination 2022
D − −
Enter your Admit Card Number :
IMPORTANT INSTRUCTIONS
• Part (A) consists of multiple-choice questions. There may be multiple correct choices. You have to select all
the correct options and no incorrect option to get full marks. There is no partial credit.
• For questions in part (A), you have to provide the answers on the computer. You only have to choose the
appropriate answer(s) from the choices provided. If the answer is parts (a) and (c), choose only (a) and (c).
• For questions in part (B), you have to write your answer with a short explanation in the space provided for
the question.
• Part(A) will be used for screening. Part (B) will be graded only if you score a certain minimum in part
(A). However your scores in both parts will be used while making the final decision.
• For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr , n Pr , n!
etc.
• f is said to be surjective (or onto) for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all y ∈ B and
g(f (x)) = x for all x ∈ A.
• For a matrix A, AT denotes the transpose of A. For a square matrix A, |A| denotes the determinant of A
and trace(A) denotes the trace of A — namely the sum of the diagonal elements of A.
• A diagonal matrix is a square matrix D with all off-diagonal entries equal to zero i.e. dij = 0 for all i ̸= j.
• An upper triangular matrix is a square matrix A for which all entries below the diagonal are zero, i.e. aij = 0
for i > j.
• A symmetric matrix is a square matrix S for which sij = sji for all i ̸= j.
1
Part A
Multiple-choice questions
Let E(T ) and V(T ) denote the expectation and the variance of a random variable T . Which of the following
statements is/are true?
(a) E(T 2 ) = np(1 − p)n−1 and V(T ) = np(1 − p)n−1 (1 − (np(1 − p)n−1 ))
2
2. Consider the following code, in which A is an array indexed from 0 and n is the number of elements in A.
function foo (A , n ) {
L = 0;
R = n - 1;
while ( L <= R ) {
i = ceil (( L + R )/2);
if ( A [ i ] < i ) {
L = i + 1;
} else {
if ( A [ i ] > i ) {
R = i - 1;
} else {
return ( i );
}
}
}
return ( -1);
}
Here, ceil(x) returns the smallest integer bigger than or equal to the number x.
If A = [-5, -4, -3, -2, -1, 4, 6, 8, 10, 12], what will foo(A, 10) return?
(a) -5
(b) -1
(c) 4
(d) 6
(eix − e−ix )
tan x = .
i(eix + e−ix )
1 1 1
(c) + + + · · · < 1.
1·2 2·3 3·4
(d) The function f (x) defined as
(
3 cos 3x, 0 < x < π/6
f (x) =
0 otherwise,
3
4. Let E and F be events such that P (E ∩ F c ) = 0.2, P (F ∩ E c ) = 0.3, P ((E ∩ F )c ) = 0.7, where, for an event
E, the notation E c denotes the complement of the event. Then we can conclude that
(a) P (E ∪ F ) = 0.8.
(b) P (E c ∩ F c ) = 0.3.
(c) P (F ) = 0.6.
(d) P (E) = 0.6.
5. Let A, B be n × n invertible matrices of real numbers. Let C = I + AAT , D = I + BAAT B T . We can
conclude that
(a) (AB)−1 = (I + B −1 A−1 )
(b) (AB)−1 = A−1 B −1
(c) C = CT
(d) D = DT
6. A matrix C is said to be symmetric if C T = C. Which of the following is/are true? Let A, B be n × n
matrices.
(a) If A is symmetric and invertible, then A−1 is also symmetric and invertible.
(b) If A and B are symmetric, then C = AB is also symmetric.
(c) If A and B are invertible, then C = AB is also invertible.
(d) If A and B are symmetric, then D = A + B is also symmetric.
7. Which of the following statements is/are true?
(a) Let A be a n × m matrix with n < m. Then there is a nonzero solution y with Ay = 0 only if A has
full row rank.
(b) Let A be a n × m matrix with n > m. There is a nonzero solution y with Ay = 0.
(c) The row rank of an n × m matrix is equal to its column rank only when n = m.
(d) Let A be an n × n matrix. Suppose A = BC, where B has size n × r and C has size r × n. The rank
of A is less than or equal to r.
8. Let n ≥ 5 be a natural number, let X = {x1 , x2 , ..., xn }, and let Y = {y1 , y2 }. Let F be the set of functions
from X to Y and G be the set of bijective functions from X to Y . Then
(a) The number of functions in F equals n2 .
(b) The number of functions in F equals 2n .
(c) The number of functions in G equals n2 − 2.
(d) The number of functions in G equals 0.
9. In order to select a debating team to represent a school, 7 students from class XII and 13 students from class
XI were shortlisted and were undergoing trials. The coach had to select a team of 5 students, out of which
at least two students should be from each class. One out of the 5 students was to be named as team leader,
who was to be from class XII. Two teams with the same members but different leaders are considered to be
two different
teams. The number
of different teams the coach can select is
7 13 7 13
(a) 2 × × + ×
2 3 3 2
7 13 7 13
(b) × + ×
2 3 3 2
7 13 7 13
(c) 2 × × +3× ×
2 3 3 2
7 13 7 13
(d) 3 × × +2× ×
2 3 3 2
4
10. Which of the following plots correspond to a function whose derivative is continuous?
I. I
I Ciii)
t ( in
5
11. Which of the following plots correspond to a bijective function?
0 . I 0
I 1
Liii) ( ir)
12. A relation R on the set A = {a, b, c, d} is defined by reading the columns of the following table from top to
bottom. If a column in the table reads (x, y, 1) it means x is related to y in R. If a column in the table reads
(x, y, 0) it means x is not related to y.
a b c d a b c d a b c d a b c d
a a a a b b b b c c c c d d d d
0 0 1 0 1 0 0 0 1 1 0 1 0 0 1 0
For instance, from the fifth column we have, (a, b) ∈ R, and from the second we have (b, a) ∈
/ R.
Another relation S on the set A is defined as: for any x, y ∈ A, the pair (x, y) is in S if and only if there
exists z ∈ A such that both (x, z) ∈ R and (z, y) ∈ R hold.
Which of the following pairs are in S?
(a) (a, a)
(b) (b, b)
(c) (c, c)
(d) (d, d)
6
13. We say that a subset S of a finite set U is large if |S| > |U \ S|. Here U \ S denotes the elements of U which
are not in S and the notation |T | denotes the number of elements in a set T . Let x be the number of large
subsets of the set X = {1, 2, . . . , 10}, and let y be the number of large subsets of Y = {1, 2, . . . , 9}. Which
of the following is true?
14. A ternary tree starts with a single root node at the top of the tree. Each node in the tree can have up to
three nodes as its children. No node in the tree is the child of two different nodes. A node which has no
children is called a leaf node.
The children of a node are drawn below it, connected by edges. The level of a node v in the ternary tree is
the number of edges in the (unique) path from the root node to v. Thus, for instance, the root node is at
level 0, and each child of the root node is at level 1.
A complete ternary tree is a ternary tree in which (i) each non-leaf node has exactly three children, and (ii)
all leaf nodes are at the same level. This latter level is called the height of the complete ternary tree. The
completeNternary trees of heights 0, 1, and 2, respectively are shown in the figure below, where we use the
symbol to denote a node:
N N N
N N N
N N N
N N N N N N N N N
(a) 211 − 1
210 +2
(b) 3
310 −1
(c) 2
310 +1
(d) 2
15. Which of the following expressions take integral values for all integers n > 100 ?
3n −1
(a) 2
4n −1
(b) 2
4n −1
(c) 3
5n −1
(d) 2
7
16. At a conference attended by 1235 people, some attendees shake hands with other attendees. As a part of
the local COVID-19 tracing protocol the organizers ask each attendee to note down the number of other
attendees with whom they shook hands. Let N be the sum of all the numbers noted down by the attendees.
That is, N is the sum, taken over all attendees, of the number of other attendees with whom they shook
hands. Which of the following is guaranteed to be true about N ?
17. Let n be a positive integer and let k be a positive integer which is greater than 1. Then n can be represented
as
n = nt k t + nt−1 k t−1 + · · · + n1 k + n0
for a unique set of positive integers n0 , . . . nt . This expression is called the representation of n in base k
and is denoted by (nt nt−1 . . . n0 )k . For example the integer 264 expressed in base 3 is represented as
(1 0 0 2 1 0)3 because 264 = 1 × 35 + 2 × 32 + 1 × 3.
Which of the following expressions represent the integer (1 1 0 1 1 1 1 0)2 ?
(a) (1 1 0 0)8
(b) (1 3 4 2)5
(c) (4 3 2)7
(d) (2 2 0 2 0)3
18. There are two villages X and Y in a faraway land. It is known that each person from village X always tells
the truth, and that each person from village Y always lies.
You meet three people A, B, C who are from these villages. You are told that A and B are from the same
village. A says, “If B is from village X, then I am from village Y ”. Now C says, “If I am from village X,
then 2 + 2 = 4”.
What can you infer about the villages to which A, B, and C belong?
8
19. A stick is fixed on the ground at an angle of 60 degrees as shown in Figure 1. The part of the stick which
is above the ground—which is the part that is shown in Figure 1—has a length of 10 metres. At a certain
time T1 during the day, the sun is directly overhead at this location and its rays strike the ground at an
angle of 90 degrees. This is shown in Figure 2. At a certain later time T2 the sun’s rays strike the ground
at an angle of 60 degrees as shown in Figure 3. While Figures 2 and 3 show only the sun’s rays for the sake
of clarity, the stick is present at this location at times T1 and T2 .
Sunrays Sunrays
Stick
60° 60°
90°
What are the lengths of the shadows of the stick at times T1 and T2 , respectively?
√ √
(a) 5 3 metres and 10 3 metres
√
(b) 5 metres and 10 3 metres
(c) 5 metres and 10 metres
√
(d) 5 3 metres and 10 metres
20. A park in Chennai has walkways as depicted in the figure. The straight path from A to B is 100 metres
long. The curved part is a semicircle whose centre coincides with the midpoint of line segment AB.
A B
A woman and her dog take a walk in this park, both starting from point A at the same time. The woman
takes the straight path from A to B, while the dog goes around the semicircular path. The woman and the
dog both reach point B at the same time. If the woman takes 10 minutes to reach from point A to point B,
which of the following statements about the woman’s and dog’s walks is/are true?
(a) The average speed of the woman’s walk is between 0.15ms−1 and 0.17ms−1
(b) The average speed of the woman’s walk is between 0.17ms−1 and 0.20ms−1
(c) The average speed of the dog’s walk is between 0.25ms−1 and 0.27ms−1
(d) The average speed of the dog’s walk is between 0.27ms−1 and 0.30ms−1
9
Part (B) - Short-answer questions
For questions in part (B), you have to write your answer with a short explanation in the space provided for the
question in your answer sheet. If you need more space, you may continue on the pages provided for rough work.
Any such overflows must be clearly labeled.
1. There are three different approaches that climbers can take to reach the summit of Mount Chernoff, namely,
Approach-I, Approach-II, and Approach-III. Each attempt at the summit uses exactly one of these ap-
proaches. From climbers’ logs it is known that Approach-I is used in 40% of the attempts, and Approach-II
and Approach-III are each used in 30% of the attempts. From the same logs it is also known that in 10%
of the attempts which used Approach-I the climber lost their way and had to be rescued. Similarly, 15%
of the attempts that used Approach-II and 17% of the attempts which used Approach-III resulted in the
climber losing their way.
It is reported one day that climber Chebyshev has lost her way. What is the probability that she took
Approach-II?
10
Description for the next four questions:
Dasholytics Inc runs an online analytics dashboard. The company employs three machines—Server 1,
Server 2, and Server 3—to serve the data for the dashboard. At any point in time one of these three
machines has the job of serving the data, and the other two are kept in standby mode. Dasholytics uses a
server scheduler (software) that decides which of the three machines should serve the data at any given point
of time. The scheduler switches between data servers without disrupting the data feed to the dashboard.
The machine which is serving the data sometimes fails to do so; in this case an alert is sent out to the
Dasholytics team and they investigate and fix the problem. The time for which a machine fails to serve
data is accounted as service outage caused by that machine. For technical reasons the server scheduler is
deactivated when there is such an outage; the outage gets over only when the issue with the server is fixed
and it is put back online.
The figures below describe the server usage and outage statistics as compiled over the last one year (365
days). Please use this information to answer the questions that follow.
Figure 1: Figure (a) shows the total service outage caused by each server, as a percentage of the total time that
it served data. Figure (b) shows the total time that each server served data, as a percentage of the total duration
over which this information was collected.
2. Express the total service outage caused by all the three servers, as a percentage of the total duration over
which the information was collected.
3. What is the expected number of hours of service outage in an year (365 days)?
4. As part of their due diligence, a potential customer of Dasholytics picks a random point in time during the
year and checks the status of the dashboard. What is the probability that the customer finds that there was
a service outage at this point in time, and that Server 1 was the server responsible for serving data at that
time?
5. An alert that a service outage has been caused by one of the three servers, was sent out to the Dasholyltics
team. What is the probability that this outage was caused by Server 1?
11
6. In a question paper, there are 5 questions in part A, 4 in part B, and 3 in part C. In how many ways can a
candidate make up her choice, if she has to select 3 from part A, 2 from part B, and 2 from part C?
Let Z be a random variable that follows the normal distribution with mean 0 and variance 1. For any real
number a let Φ(a) = P(Z < a) be the probability that Z takes values smaller than a. Then
2
a
e−u /2
Z
Φ(a) = P(Z < a) = √ du.
−∞ 2π
For solving the next two problems you may assume the following approximations: Φ(−2) = 0.02, Φ(−1) =
0.16, Φ(0) = 0.5, Φ(1) = 0.84, Φ(2) = 0.98.
The weekly number of sales S at a certain car dealership is known to follow a probability distribution with
mean E(X) = 10 and variance Var(X) = 144. A performance audit picks a random sample of 36 weekly
sales figures S1 , S2 , . . . , S36 from the last two years. They find that the sample mean is 10 and the sample
variance is 144. Use this information to answer the next two questions. You may assume that n = 36 is a
large enough sample size.
7. (a) What is the probability that the average number of sales in a week will be more than 8?
(b) What is the total number of sales over the 36 weeks which were sampled?
8. Check if the following statement(s) are correct. Briefly explain your reasons.
(a) The probability that the average number of sales in a week will be more than 8 but less than 14 is
Z 14
1 u−10 2
√ e−0.5( 12 ) du
8 12 2π
(b) The probability that a salesperson would be able to sell, on an average, ten or more products in a week
is 50%.
9. Two particles move in opposite directions around a circular track. The first moves at a constant speed of 10
m/s. The speed of the second increases at a constant rate of 2 m/s every second. The particles are at the
same position A at time 0, with the second particle being momentarily at rest at t = 0. We are told that
the second meeting of these particles after time 0 takes place at the point A. We assume that the particles
magically cross each other the first time they meet with no change in their instantaneous velocities. Given
this information:
12
10. Words are formed using the characters 0 and 1. The length of a word is the number of characters in it. We
say there is a path from word x to word y if starting from the word x you can get the word y by applying
the following sequence of transformation rules finitely many times in any order.
• Replacing an occurrence of the string 101 by a 0.
• Replacing an occurrence of the string 010 by a 1.
• Replacing a 0 by a 101.
• Replacing a 1 by by a 010.
If there is a path from word x to word y we say x and y are equivalent or that they are in the same equivalence
class. For example the four letter word 1011 is equivalent to the two letter word 01, since the prefix 101 in
1011 can be replaced by a 0 to get 01.
We say x has a shorter description if there is a word of shorter length equivalent to it.
(a) State true or false: for any word x there is a unique shortest word in its equivalence class.
(b) How many three letter words are there in this language which have no shorter descriptions and which
are all in different equivalance classes?
11. You are given an 8 × 8 chessboard and a large supply of T -shaped tiles and square-shaped tiles of the kind
shown below.
Note that the squares in these two shaped tiles are of the same size as the black/white squares on the
chessboard.
We wish to cover the squares of the chess board using these tiles. Each square of the chessboard must be
occupied by exactly one square from a tile; we are not allowed to break the tiles.
(a) Is it possible to cover the chessboard with 16 T shaped tiles? Why?
(b) Is it possible to cover the chessboard with 15 T shaped tiles and one square tile? Why?
12. To guard against login attempts by bots, Alphabet Bank of India uses a captcha challenge on their net
banking login page. The captcha text is a sequence of five letters from the English alphabet.
(a) An early version of the captcha text consisted of a sequence of five distinct letters picked uniformly
at random from the lower-case English alphabet, {a, b, c, . . . , z}. Two examples of such captcha text
are: qfhdk and smgft. An example of such captcha text which has its first two letters in increasing
alphabetical order is: vxztr.
What is the probability that the captcha text generated in this way has the first two letters in
increasing alphabetical order, and why?
(b) After a couple of years the bank noticed that some bots had become very good at cracking the captcha.
So they updated their software so that it now generates the captcha text by picking five distinct letters
uniformly at random from the English alphabet, where the case of each letter can be either upper or
lower. That is, the letters are now picked from the set {a, b, c, . . . , z, A, B, C, . . . , Z}. Note that the
same letter does not appear in both lower and upper case in the same captcha text.
Two examples of the captcha text generated by this version are: QFhDk and sMgfT. Examples of such
captcha text with the first two letters in increasing alphabetical order are: VxPTr and vXptR. Note that
the case of the letter does not matter when deciding the alphabetical order.
What is the probability that the captcha text generated in this way has the first two letters in increasing
alphabetical order, and why?
13
13. Among 40 bicycle gears, 28 are broken or rusted but not both, 6 are non-defective (i.e. neither rusted nor
broken), and the number of broken gears equals the number of rusted ones. How many gears are rusted?
14. Consider the following code, in which A and B are arrays indexed from 0 and lenA and lenB are the numbers
of elements in A and B, respectively.
function foo (A , B , lenA , lenB ) {
acc = 0;
for i = 0 to ( lenA - 1) {
acc = A [ i ]^ acc ;
}
print ( acc );
for i = 0 to ( lenB - 1) {
acc = B [ i ]^ acc ;
}
print ( acc );
}
Here, a^b represents the bitwise Exclusive OR function over variables a and b.
Given integers a and b, we write them in binary, padded by zeros to the left to make them of equal length.
We then apply Exclusive OR to these binary representations bitwise. The operation a^b denotes the in-
teger value obtained by performing bitwise Exclusive OR on the binary values of a and b. For example,
3^4 = 011^100 = 111 = 7, and 9^5 = 1001^0101 = 1100 = 12. The truth table for the Exclusive OR
function is provided.
a b a^b
0 0 0
0 1 1
1 0 1
1 1 0
Let A = [1, 3, 3, 5, 5] and B = [9, 5, 5, 3, 3, 1]. What are the two values printed by foo(A,B,5,6),
in order?
14
15. Consider the following code, in which A and B are arrays indexed from 0 and lenA and lenB are the numbers
of elements in A and B, respectively.
function foo (A , B , lenA , lenB ) {
sum = lenA + lenB ;
i = 0;
j = 0;
for t = 0 to ( sum - 1) {
if ( A [ i ] < B [ j ]) {
i = i + 1;
} else {
if ( A [ i ] > B [ j ]) {
j = j + 1;
} else {
return A [ i ];
}
}
}
return ( -1);
}
Let A = [2, 4, 6, 7, 8, 9, 10] and B = [1, 3, 5, 7, 9, 11, 13]. What does foo(A,B,7,7) return?
16. Consider the following code, in which A is an integer array of length n indexed from 0, and x is an integer.
function foo (A ,x , n ) {
found = False ;
if ( A [ i ] == x ) {
found = True ;
}
}
return ( i );
}
Here, randInt(0,n) returns an integer picked uniformly at random from the range {0, 1, . . . , (n − 1)}.
All integers present in array A are distinct, and integer x is present in array A. Suppose we make the call
foo(A,x,n). What is the expected number of times that the call randInd(0, n) is made from within this
call to foo(A,x,n)?
17. A graph consists of a finite set of vertices, and edges between some (unordered) pairs of these vertices. The
graphs in this question have no loops (an edge between a vertex and itself) or multiple edges (more than
one edge between the same pair of vertices). A vertex v in a graph is said to be a global vertex if there is an
edge between v and every other vertex in the graph.
A graph G is constructed as follows: First, its vertex set is assigned to be the set {v1 , v2 , . . . , v10 }. Next,
between each pair of distinct vertices vi , vj , an edge is added with probability 21 .
15
18. The sum of two positive integers a and b is 48 and their least common multiple is 189. Find a and b.
19. Recall that for an n × n matrix A, det(A) = det(AT ). Here AT is the transpose of matrix A. An n × n
matrix A is said to be skew-symmetric if ai,j = −aj,i , where aij denotes the element in the ith row and j th
column,for all 1 ≤ i, j ≤ n and all elements are real.
20. An object X is viewed from a camera placed at point C1 . The camera is then moved to the point C2 and
X is again viewed from this new position. Suppose H is the plane containing the points C1 and C2 . Let H ′
be a plane parallel to H lying between the object X and the camera positions. Let f denote the distance
between H and H ′ . Let X1 , X2 be the points of intersection of H ′ with the line segments joining X with C1
and C2 respectively.
Let x1 be the distance between the reference axis L1 and X1 . Similarly let x2 be the distance between the
reference axis L2 and X2 . The axes L1 and L2 are both perpendicular to the camera plane H. The difference
|x1 − x2 | is called the disparity in views. Find a formula for the depth z i.e. distance of the object from the
camera plane in terms of f , the distance b between the cameras, and the disparity.
• ✗
H
:¥"
H
C
l
,
← b →
1
ti
Cz
:
↓ .
Z
16
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination 2023
IMPORTANT INSTRUCTIONS
• Part (A) consists of multiple-choice questions. There may be multiple correct choices. You have to select all
the correct options and no incorrect option to get full marks. There is no partial credit.
• For questions in part (A), you have to provide the answers on the computer. You only have to choose the
appropriate answer(s) from the choices provided. If the answer is parts (a) and (c), choose only (a) and (c).
• For questions in part (B), you have to write your answer with a short explanation in the space provided for
the question.
• Part(A) will be used for screening. Part (B) will be graded only if you score a certain minimum in part
(A). However your scores in both parts will be used while making the final decision.
• For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr , n Pr , n!
etc.
• f is said to be surjective (or onto) for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all y ∈ B and
g(f (x)) = x for all x ∈ A.
• For a matrix A, AT denotes the transpose of A. For a square matrix A, |A| denotes the determinant of A
and trace(A) denotes the trace of A — namely the sum of the diagonal elements of A.
• A diagonal matrix is a square matrix D with all off-diagonal entries equal to zero i.e. dij = 0 for all i 6= j.
• An upper triangular matrix is a square matrix A for which all entries below the diagonal are zero, i.e. aij = 0
for i > j.
• A symmetric matrix is a square matrix S for which sij = sji for all i 6= j.
1
Part (A) - Multiple-choice questions
1. Six children — Abhay, Bhavna, Charanjit, Divya, Enakshi and Farid — are
sitting, in that order, around a circular table at a birthday party, as shown on
the right. Each of them may be seated or standing.
They play a game, as follows. The birthday girl’s father calls out the initials
of a pair of children seated next to each other. The children whose initials are
called out then change their position from sitting to standing or vice versa.
Initially, all children are seated. Which of the following announcements will
result in an arrangement where Abhay and Enakshi are standing and the other
four children are seated?
(a) F A, DE, BC, CD, AB, F A
(b) AB, BC, DE, EF, EF, DE
(c) AB, CD, BC, EF, DE, EF
(d) AB, CD, F A, BC, AB, DE
x4 + 1 x3 − x
f (x) = ; g(x) = .
x3 − 1 x3 + x
Which of the following is/are true?
4. Let a1 < a2 < a3 < a4 < . . . < . . . be a sequence of infinitely many positive integers which are in arithmetic
progression. Furthermore, suppose a2 , a4 , a8 are in geometric progression. Which of the following is/are
true?
(a) For every positive integer n, there is a triple of numbers ai < aj < ak which are in geometric progression
with ratio n, i.e. aj = ai n, ak = aj n.
(b) If i < j then ai divides aj .
(c) There are only finitely many n for which there are infinitely many triples i < j < k with ai , aj , ak in
arithmetic progression with common difference n.
(d) Integers a10 , a30 , a90 are in geometric progression.
5. Let A be a 20 × 11 matrix with real entries. After performing some row operations on A, we get a matrix
B which has 12 nonzero rows. Which of the following is/ are true?
2
(a) Rank of A is 12.
(b) Rank of A and B are not related.
(c) If v is a vector such that Av = 0 then Bv is also 0.
(d) Rank of B is at most 11.
6. Let f be a single variable, real valued function such that all its derivatives exist. We say that f changes sign
at some point x0 in the domain if the product f (x0 + ) · f (x0 − ) < 0 for small enough, positive .
• A point x0 in the domain is called a turning point of f , if the first derivative f 0 changes sign at x0 .
• A point x0 in the domain is called flex point of f , if the second derivative f 00 changes sign at x0 .
7. Solitaire Tic-Tac-Toe is a new game on the market. Instead of adding X’s and O’s to an empty 3 × 3 grid,
you start with a 3 × 3 grid in which every position already has an X or an O. In each move, you select a row,
column or diagonal and reverse all the entries along the chosen line: all X’s become O’s and all O’s become
X’s.
For instance, here is a sequence of possible moves.
Given an arrangement S, we want to explore all arrangements of the grid that we can generate starting with
S. What is the smallest number m such that each such arrangement can be reached using at most m moves,
starting with S?
(a) 8
(b) 16
(c) 64
(d) 256
8. A bug starts walking from the origin of a two dimensional plane. It walks 1 step up, 1/2 step to the left
then 1/4 step down, then 1/8 step to the right, then 1/16 step up and so on, forever. In (x, y)-coordinates,
its final position is given by
(a) (− 32 , 45 )
(b) (− 25 , 43 )
(c) (− 52 , 45 )
(d) (− 23 , 43 )
9. Let A, B, C be events such that P (A) = P (B) = P (C) = 0.5, P (A ∩ B) = 0.3, P (A ∩ C) = 0. Which of the
following is/are true?
(a) P (A ∪ B) = 0.75
(b) P (A ∪ C) = 1
3
(c) P (B ∩ C) = 0.2
(d) P (B ∪ C) = 0.9
10. The mean and variance of a data set of size n ≥ 100 are 1.1 and 4.3 respectively. It was then discovered that
one data point was wrongly recorded as -0.9 and should be ignored. Then we can conclude that the mean µ
and variance σ 2 of the n − 1 data points satisfy
11. An n × n matrix A = (aij ) is said to be antisymmetric if aij = −aji for all 1 ≤ i, j ≤ n. Which of the
following is/are true?
(a) If A is antisymmetric then all its principal diagonal entries are zero.
(b) If A, B are antisymmetric matrices then the product AB need not be antisymmetric.
(c) If A is antisymmetric then A2 is symmetric.
(d) A nonzero 3 × 3 antisymmetric matrix is invertible.
12. Consider the set S = {0, 1, 2, . . . , n − 1} such that n ≥ 2. Let x be an element sampled uniformly at random
from S. Let y denote (x + 2n ) mod n. Which of the following statements is/are true?
√ √
(a) Pr y = b n − 1c = b n−1c
n
(b) Pr[x = a, y = b] = Pr[x = a] · Pr[y = b] for all a, b ∈ S
(c) y is always an element of S
(d) Pr [y = blog2 (n − 1)c] = 1/n
13. A perfect shuffle of a deck of cards divides the deck into two equal parts and then interleaves the cards from
each half, starting with the first card of the first half.
For instance, if we shuffle a deck of cards containing 10 cards arranged [1, 2, 3, 4, 5, 6, 7, 8, 9, 10], we first
create two equal decks with cards [1, 2, 3, 4, 5] and [6, 7, 8, 9, 10] and then interleave them to get a new deck
[1, 6, 2, 7, 3, 8, 4, 9, 5, 10].
We start with the deck [8, 1, 4, 5, 3, 6, 2, 7] and keep shuffling. Which card(s) will never appear next to 5?
(a) 1
(b) 2
(c) 7
(d) 8
14. Consider the following pseudocodes of two functions, where u % 2 denotes the remainder when u is divided
by 2. The function abs(v) returns the absolute value of an integer v.
function foo1 ( u ):
if u % 2 == 0 AND abs ( u ) > 0:
u = u + foo2 (u -1)
return u
function foo2 ( v ):
if v % 2 == 1 AND abs ( v ) > 1:
v = v + foo1 (v -1)
return v
4
Which of the following is/are true?
16. Let X, Y , Z be finite sets. Which of the following statement(s) is/are true?
(a) Let f : X → Y , g : Y → Z be functions. such that the composite function g ◦ f : X → Z is onto. Then
both g, f have to be onto.
(b) Assume the number of elements of X, denoted as |X|, is strictly less than |Y | and also assume that
|X| ≤ |Z|. There exists a one-one function f : X → Y and a g : Y → Z which is not one-one such that
g ◦ f : X → Z is one-one.
(c) Let idX be the identity function on X, i.e. idX (x) = x for all x ∈ X. Let f : X → Y be a function.
Then there exists a function g : Y → X such that g ◦ f = idX exists.
(d) Denote by idY the identity function on Y , idY (y) = y for all y ∈ Y . Then there exists g : Y → X such
that f ◦ g = idY if and only if f is onto.
17. Consider the following real valued functions defined on appropriate domains:
x
f (x) = , g(x) = x ln(x).
x + sin x
Which of the following is/are true?
18. Consider the pseudocode below, where n % 6 denotes the remainder when n is divided by 6. The notation
n//2 stands for integer division, i.e., 15//2 = 7, 36//2 = 18, 49//2 = 24.
function sixer ( n ):
count = 0
while n > 0:
if n % 6 == 0:
n = n - 1
else :
n = n //2
count = count + 1
return count
Which of the following is true when sixer(n) is invoked with sufficiently large n, say n ≥ 106 ?
5
(b) The value of count is approximately n/2
(c) The value of count is approximately log2 (n)
(d) The value of count is approximately (log2 (n))2
19. In a football league, a collection of teams play against each other a number of times. A team gets 3 points
for each match that it wins, 1 point for each match that it draws and 0 points for each match that it loses.
The following table gives the point standings after four teams have played a total of 7 matches. At this
stage, each team has played every other team at least one.
(a) 3
(b) 4
(c) 5
(d) 6
20. A new game show on TV has 100 boxes numbered 1, 2, . . . , 100, each containing a mystery prize. The
prizes are of different types, a, b, c, . . . , in decreasing order of value, and are distributed randomly among
the boxes. The most expensive item is of type a, a diamond ring, and there is exactly 1 of these. You are
told that the number of items at least doubles as you move to the next category — there are at least twice
as many items of type b as of type a, at least twice as many items of type c as of type b and so on.
You ask for the type of item in box 45. Instead of being given a direct answer, you are told that there are
31 items of the same type as box 45 in boxes 1 to 44 and 43 items of the same type as box 45 in boxes 46
to 100.
Which of the following statements can be true?
6
Part (B) - Short-answer questions
For questions in part (B), you have to write your answer with a short explanation in the space provided for the
question in your answer sheet. If you need more space, you may continue on the pages provided for rough work.
Any such overflows must be clearly labeled.
1. There are 5 friends A, B, C, D, E. Because of a heated argument not all of them are on speaking terms
anymore. The array below describes who is talking to whom. A value of 1 indicates that the pair is on
speaking terms, while a 0 indicates that they are not.
A B C D E
A - 1 1 1 1
B 1 - 1 0 1
C 1 1 - 1 0
D 1 0 1 - 1
E 1 1 0 1 1
A gossip route is an ordered sequence of all the five friends such that every person hears the gossip from
exactly one friend (with whom they are on speaking terms) and shares it with exactly one other friend (with
whom they are on speaking terms). The friend who starts the gossip doesn’t hear it from anyone else and
the fifth friend doesn’t pass it on to anybody.
Answer the following questions:
(a) Suppose A starts spreading gossip along a gossip route and E hears it the last. Who is the third person
to hear it?
(b) List all the gossip routes from B to E.
(c) There is another dispute between the friends. As a result, A is now not speaking with B and D. List
all the gossip routes starting from A.
2. Two friends A and B are playing a coin flipping game with a fair coin, based on the following rules:
Suppose A is the first player to flip the coin. What is the probability that A will win the game.
3. Consider the following real valued function defined on the entire set of real numbers:
1
f (x) = .
1 + e−x
Show that f 0 (x) = f (x)(1 − f (x)).
4. Let f be the following function defined on integers:
1
f (n) = √
3n + 3
√ h i
Compute 3 f (−5) + f (−4) + f (−3) + · · · + f (4) + f (5) + f (6)
7
5. Find the determinant of the following 5 × 5 matrix:
1 2 0 0 0
2 5 2 0 0
0 2 5 2 0
0 0 2 5 2
0 0 0 2 5
7. Let N = 2150 . How many bits are required to write N in binary (base 2)? How many digits are required to
write N in decimal (base 10)? You may assume that log10 2 = 0.30103.
8. A domino is a sheet of paper with one number from {0, 1, 2, 3, 4, 5, 6, 7, 8, 9} printed on each half. For example,
a 4−4 domino has 4 printed on both halves. A 0−4 domino has 0 printed on one half and 4 on the other
half. The order is not important, so a 0−4 domino is the same as a 4−0 domino.
A complete set of dominos is a set of dominos containing exactly one copy of each different domino.
9. There are three classrooms, C1 , C2 , and C3 . In C1 there are 5 boys and 5 girls. C2 has 3 boys and 5 girls.
C3 has 5 boys and 3 girls. We select a classroom and then a student in the classroom. The probability of
3 3 4
selecting classrooms C1 , C2 , and C3 are 10 , 10 , and 10 , respectively. Once a room is selected, a student is
picked uniformly at random from the class.
(a) What is the probability that the selected classroom is C3 and the chosen student is a girl?
(b) What is the probability that the selected classroom is C3 given that the chosen student is a girl?
10. How many integers in the set {1, 2, . . . , 1000} are relatively prime to 1000? Recall that two integers are
relatively prime if the only common factor they have is 1.
12. Football teams T1 and T2 play two games against each other in the Premier League. It is assumed that the
outcomes of the two games are independent of each other. The probabilities of T1 winning, drawing and
losing against T2 are 21 , 61 and 13 respectively. Each team gets 3 points for a win, 1 point for a draw and 0
points for a loss in a game. Let X and Y denote the total points scored in these two games by team T1 and
T2 , respectively.
(a) Find P (X = Y ).
(b) Find E(X).
13. Let A, B and C denote arrays of real numbers, where B has n-1 entries and A, C have n entries each. Consider
the following algorithm involving the three given arrays.
8
for k from 2 to n :
t = B [k -1]
B [k -1] = t / A [k -1]
A [ k ] = A [ k ] - t * B [k -1]
end for
for k from 2 to n :
C [ k ] = C [ k ] - B [k -1] * B [k -1]
end for
C [ n ] = C [ n ]/ A [ n ]
for k from n -1 to 1 with steps of -1:
C [ k ] = ( b [ k ]/ A [ k ]) - B [ k ] * b [ k +1]
end for
An arithmetic operation involves addition, subtraction, multiplication or division of real numbers. How
many arithmetic operations, in total, are performed in the algorithm above?
Note: Integer subtraction in array indices, like B[k-1], is not to be counted as an arithmetic operation.
14. In the following pseudocode segment, A denotes an array and len(A) denotes the number of elements in that
array. The array is indexed from 1 to len(A). Write down the array A in each iteration of the for loop when
the input array is <20, 3, 9, 12, 70, 6>.
function weirdify ( A ):
for i from 1 to len ( A ):
if i % 2 == 0:
A [ i ] = A [ i /2]* A [ i ]
else if i * i > len ( A ):
A [ i ] = A [i -2] + 4
else :
A[i] = A[i] - 1
15. Consider a city with n East-West Streets (EWS) and n North-South Avenues (NSA). The EWS are the line
segments {y = j | 1 ≤ x ≤ n} for all j ∈ {1, 2, . . . , n} and the NSA are the line segments {x = i | 1 ≤ y ≤ n}
for all i ∈ {1, 2, . . . , n}. A junction is a pair (i, j) where avenue i intersects street j. How many junctions
are there in the city?
For increased safety, the city council decides to place cameras at various junctions in the city. The cameras
being super-powerful, can observe the entire street and avenue corresponding to the junction that they are
placed at. For instance, a camera placed at the junction (i, j) can observe both avenue i and street j. Write
down an expression for the minimum number of cameras needed to observe every street and avenue in the
city.
Justify your answers.
17. Each lawyer on a certain remote island is either honest or dishonest (but not both).
Is it possible for a lawyer on this island to claim that he/ she is dishonest? Explain. A judge asks lawyer A,
“are you honest”? Before A could answer, lawyer B says “A will say yes. But then, he’ll be lying”. Which
lawyer is honest and which one is dishonest? Explain.
18. A new restaurant chain Burger Paradise has recently opened in Chennai. Burger Paradise offers a variety
of burgers, including vegetarian options, as well as sides and drinks. According to the restaurant’s data,
9
20% of customers order vegetarian burgers. The restaurant’s data also indicates that customers who order
a burger are twice as likely to order a side of fries than a side of salad.
(a) If the restaurant serves 200 customers daily, what is the expected number of vegetarian burgers they
will sell over a week?
(b) If 30% of the customers order a burger and 30% of those who order a burger order a side of salad, what
is the probability that a customer orders a burger along with a side of fries?
19. Burger Paradise plans to expand to other cities and is considering opening a new branch in Coimbatore. They
have identified three potential locations, A, B and C, and are evaluating the profitability of each location.
Based on their research, they estimate that the fixed cost for opening a new location will be |50, 00, 000,
|70, 00, 000 and |65, 00, 000 at A, B and C, respectively. They also estimate the variable cost per customer
to be |85 and the average revenue per customer to be |150 at all three locations. They expect to serve
100, 000, 150, 000 and 130, 000 customers in the first year at locations A, B and C, respectively
Which location in Coimbatore is expected to be the most profitable in the first year of operation, and what
is the expected profit at this location?
20. Towns A, B and C are connected to each other by several roads, with at least one road connecting each pair.
In going from one town to another, one can take the road that connects them directly or could travel via
the third town. It is given that, in total, there are 33 roads from A to B, including those via C. Similarly,
there are 23 roads from B to C, including those via A. How many routes are there from A to C, including
those via B?
10
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination 2024
IMPORTANT INSTRUCTIONS
• Part (A) consists of multiple-choice questions. There may be multiple correct choices. You have to select
all the correct options and no incorrect option to get full marks. There is no partial credit.
• For questions in part (A), you have to provide the answers on the computer. You only have to choose
the appropriate answer(s) from the choices provided. If the answer is parts (a) and (c), choose only (a)
and (c).
• For questions in part (B), you have to write your answer with a short explanation in the space provided
for the question.
• Part(A) will be used for screening. Part (B) will be graded only if you score a certain minimum in
part (A). However your scores in both parts will be used while making the final decision.
• For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr , n Pr ,
n! etc.
• f is said to be surjective (or onto) for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all y ∈ B
and g(f (x)) = x for all x ∈ A.
• For a matrix A, AT denotes the transpose of A. For a square matrix A, |A| denotes the determinant of
A and trace(A) denotes the trace of A — namely the sum of the diagonal elements of A.
• A diagonal matrix is a square matrix D with all off-diagonal entries equal to zero i.e. dij = 0 for all
i ̸= j.
• An upper triangular matrix is a square matrix A for which all entries below the diagonal are zero, i.e.
aij = 0 for i > j.
• A symmetric matrix is a square matrix S for which sij = sji for all i ̸= j.
1
Part (A) - Multiple-choice questions
A = 1234679580, B = 1234789560.
(a) Let f (x) = x3 + x − 1 for x ∈ R. Then the equation f (x) = 0 has at least one root in [−1, 0).
(b) Let f (x) = x3 + x − 1 for x ∈ R. Then the equation f (x) = 0 has at least one root in [0, 1).
(c) Let f (x) = x3 + x + 1 for x ∈ R. Then the equation f (x) = 0 has at least one root in [0, 1).
(d) Let f (x) = x3 + x + 1 for x ∈ R. Then the equation f (x) = 0 has at least one root in [−1, 0).
3. 26 children participated in a chess tournament. A child got two points for winning, zero for losing and
one point for a draw. Each child played against every other child. After the tournament was over no
child had an odd score. There were no draws in the entire tournament and no two players had the
same score. For convenience assume that the children are named A, B, C, . . . , Z, by the 26 letters of the
English alphabet in increasing order of scores, so A has lowest score, Z has highest score. Thus we have
A < B < C < · · · < X < Y < Z. Pick all statements which are true.
(a) K lost to Q
(b) K lost to B
(c) M lost to N
(d) If L lost to M then N lost to M.
4. 14 teams participate in a volleyball tournament. Each team plays the other exactly once. There are no
draws. Assume the teams are labeled by j, 1 ≤ j ≤ 14. Let xj denote the number of games team j wins
and yj the number of games that team j lost. Pick the correct alternative(s):
x2j = yj2 .
P P
(a) j j
x2j > yj2 .
P P
(b) j j
P P
(c) j xj = j yj .
P P
(d) j |xj | = j |yj |.
(a) If x2 = y 2 then x = y.
(b) If x3 = y 3 then x = y.
(c) If x < y then x2 < y 2 .
(d) If x < y then x3 < y 3 .
2
6. Suppose that A is an n × n matrix with n ≥ 6. For an n × 1 vector b consider the equations
where AT is the transpose of the matrix A. Which of the following statements are correct?
(a) If equation (??) admits a solution for all b, then A−1 exists.
(b) If equation (??) admits a solution for all b, then equation (??) also admits a solution for all b.
(c) If equation (??) admits a solution for some b, then A−1 exists.
(d) If equation (??) admits a solution for some b, then equation (??) also admits a solution for that b.
9. Let x be a variable that takes real values, and let f (x), g(x), h(x) be three polynomials with real-valued
coefficients. Further, let f (x) be a polynomial of degree 1, g(x) a polynomial of degree 2, and h(x) a
polynomial of degree 3. Which of the following statements is/are always true for any three polynomials
of these types?
(a) The graphs of f (x) and g(x) intersect at one or more points.
(b) The graphs of f (x) and h(x) intersect at one or more points.
(c) The graphs of g(x) and h(x) intersect at one or more points.
10. A spherical ball of ice of radius 20m is dropped in a vat of hot water. The ice melts in such a way that
(i) the shape of the ball remains spherical, and (ii) the radius of the ball decreases at a constant rate of
0.5ms−1 . At what rate does the volume of the ice ball decrease, when the radius of the ball is 15m?
11. Let x be a real-valued variable. What is the range of the function f (x) = sin2 x − sin x + 2?
(a) [0, 2]
(b) [1, 2]
(c) [1, 4]
(d) [ 74 , 4]
3
12. In the following code, A is an array indexed from 0 whose elements are all positive integers, and n is the
number of elements in A. It is given that n is at least 2. The operator * denotes multiplication.
function foo (A , n ) {
if A [0] > A [1] {
first = A [0];
second = A [1];
} else {
first = A [1];
second = A [0];
}
If A = [15, 7, 16, 12, 17, 14, 16, 4, 13, 12], what will foo(A, 10) return?
(a) 28
(b) 144
(c) 180
(d) 272
4
13. In the following code, A is an array indexed from 0 whose elements are all positive integers, and n is the
number of elements in A.
function foo (A , n ) {
max = 0;
curr = 0;
(a) 2
(b) 3
(c) 4
(d) 5
14. A prominent newspaper conducted a survey among a carefully chosen sample of 1,00,000 voters under
the age of 25. A randomly chosen subset of 60% of this sample were asked the following question: “Have
you ever voted in a general election?” The remaining 40% were asked the following, different question:
“Is it true that you have never voted in a general election?”
The editor in charge of collating the data from the survey, accidentally deleted some of the contents of the
survey database. The only information that survived this mishap was that a total of 54,000 respondents
replied Yes to the question that they got. Specifically, it is not known how many of these Yes answers
correspond to the first question, and how many to the second.
Assume that the sampling was done properly and that the respondents answered truthfully. What
estimate can we derive from just the total number of Yes answers, about the percentage of voters under
the age of 25 that have voted in some general election?
5
15. Let f, g be two real valued functions defined on the set of real numbers. Which of the following statements
are true?
(a) If f (x) is continuous and g(x) discontinuous then the function f (x)+g(x) is necessarily discontinuous.
(b) If f (x) is continuous and g(x) discontinuous then the function f (x)·g(x) is necessarily discontinuous.
(c) If the functions f (x), g(x) are discontinuous at a point c in the domain the function f (x) + g(x) is
also discontinuous at c.
(d) If the functions f (x), g(x) are discontinuous at a point c in the domain the function f (x) · g(x) is
also discontinuous at c.
16. In the following code, A is an array indexed from 0 whose elements are all positive integers, n is the
number of elements in A, and x is a positive integer. The call abs(z) returns the absolute value of integer
z.
function foo (A ,n , x ) {
max = 0;
return ( max );
}
(a) 2
(b) 4
(c) 6
(d) 9
17. One day, Captain Haddock receives a mysterious letter with a confusing paragraph. Captain Haddock and
Tintin are investigating the matter. There are two possible suspects: Professor Calculus and Thomson
& Thompson. Based on their past experience:
• The probability that Professor Calculus sends a letter is 60%, while the probability that Thomson
& Thompson send a letter is 40%.
• When Professor Calculus sends letters, there is an 80% probability that the letter contains a con-
fusing paragraph.
• When Thomson & Thompson send letters, there is a 5% probability that the letter contains a
confusing paragraph.
What is the probability that the letter was sent by Professor Calculus?
(a) 0.96
(b) 0.80
(c) 0.50
(d) 0.48
6
18. Let f be a function on the positive real numbers such that f (xy) = f (x) + f (y). If f (2024) = 2 then
which of the following statement(s) is/ are true?
1
(a) f ( 2024 )=1
1
(b) f ( 2024 ) = −1
1
(c) f ( 2024 ) = −2
1
(d) f ( 2024 )=2
19. We shuffle the deck [3, 6, 11, 4, 7, 9, 2, 8, 5, 10, 12, 1]. What are the neighbours of 4 after the shuffle?
(a) 1
(b) 5
(c) 10
(d) 12
20. After shuffling once we obtain a deck with cards [15, 6, 4, 1, 13, 9, 8, 7, 12, 11, 5, 10, 3, 14, 2, 16]. What were
the neighbours of 2 before the deck was shuffled?
(a) 3
(b) 6
(c) 7
(d) 14
7
Part (B) - Short-answer questions
For questions in part (B), you have to write your answer with a short explanation in the space
provided for the question in your answer sheet. If you need more space, you may continue on the
pages provided for rough work. Any such overflows must be clearly labeled.
1. In the Easy Round, all questions are easy, and each prize is |1000. Guest Chatur knows all the answers.
What is the expected earnings for Chatur in this round? Explain your answer.
2. To proceed to the next round, a guest must earn at least |7000 in the Easy Round. What is the
probability that guest Chatur, who knows all the answers of the Easy Round, progresses to the second
round? Explain your answer.
r r
x y 5
+ =
y x 2
x y 9
√ +√ = .
y x 2
8
Questions 4 and 5 are based on the following description.
The following question appeared in a quiz:
“Write the code for a function SecondBest(A,n) that takes an array A and a positive integer n
as arguments. The elements of A are all integers, and n is the number of elements in A. The call
SecondBest(A,n) should return the second largest element in A. If A has no second largest element,
then the function should return the special value None.”
A student submitted the code below as the answer to this question. In the code the array A is indexed from 0.
function SecondBest (A , n ) {
if n == 1 {
return ( None );
}
first = A [0];
second = A [1];
if first != second {
return ( second );
} else {
return ( None );
}
}
This answer turned out to be wrong; this function gives the correct answer for some valid inputs, and wrong
answers for other valid inputs. Answer the next two questions about this function.
4. What do the following function calls return? Briefly explain your answer.
(a) SecondBest([2,2,3], 3)
(b) SecondBest([3,2,2], 3)
5. Give one example of an input array A with exactly 3 elements for which the call SecondBest(A, 3)
returns a wrong answer. What is this wrong answer? What is the correct answer?
6. Let F be the set of points on the plane with coordinates (x, y) such that ||x| − |y|| + |x| + |y| = 4. What
is the number of points in F with integer coordinates?
7. We select three points at random on the circumference of a circle. What is the probability that ∆ABC
contains the centre O in the interior?
8. Let α be a fixed real number and let f be a function from R2 to R2 defined as
Write down an expression for f 10 (x, y), where f 10 denotes the function obtained by composing f with
itself 10 times.
9
9. “I’ve defeated more than 10 FIDE masters,” a chess player boasted. “Surely, it must be fewer than 10,”
said the referee. “Well, I suppose it was at least one,” said the Grand Master. If exactly one of them
spoke the truth, how many FIDE masters did the chess player actually defeated?
10. A supplier of art material has four reams of handmade paper, three boxes of acrylic colors and two
printing blocks. The two artists in the shop want to buy one item each, but insist on having the same
kind of art material. How many items does the supplier have to take out to be sure that the artists’
demand is met?
11. In a farmer’s stable three animals, a donkey, a cow and a horse had to share two types of feed bags, one
containing hay and the other containing grain, as follows:
• If the donkey ate grain then the horse ate what the cow ate.
• If the horse ate grain then then donkey ate what the cow did not eat.
• If the cow ate hay, then the donkey ate what the horse ate.
Among all the assignments of feedbags that satisfy the above condition which animal always gets to eat
from the same feedbag?
12. There are 7 elevators in a large shopping mall, each stopping at ground floor and at most six other floors.
If at least 3 elevators stop at each floor and if it is possible to go from any floor to any other floor without
changing elevators, what is the maximum number of floors in the mall?
√ √
q q
x + 2 x − 1 + x − 2 x − 1.
Find two real numbers a, b such that the above expression is constant for a ≤ x ≤ b.
14. You are given a strange, analogue wall clock whose hour and minute hands are identical. Both the hands
move continuously and there is no second hand. How many times are there from noon to midnight when
it is not possible to tell what time is it by looking at the clock at that instant? For example, at 06 : 00
pm one can be sure that the upper hand is the minute hand, for otherwise at 12 : 30 pm the top hand
is between 12 and 1. However, a bit after 1 : 15 pm and 3 : 06 pm the clock looks identical and you
wouldn’t be able to tell the exact time.
15. Does there exist a polynomial q(x) with integer coefficients such that q(1) = 2 and q(3) = 5? Given an
example if there is one. Justify, if there is not.
16. Find the number of all 4-digit natural numbers formed with exactly two distinct digits.
17. An electronic card shuffling machine always rearranges the cards in the same way relative to the order
in which they are placed in it. One iteration of shuffling means that the cards are placed in the machine
and they are taken out after the rearrangement. Two iterations means that you place the cards in the
machine immediately after the first iteration. The ace through the king of hearts are arranged in order
with the ace on top and the king at the bottom. After 2 iterations the order of the cards, from top to
bottom, is
10, 9, Q, 8, K, 3, 4, A, 5, J, 6, 2, 7.
10
Questions 18–20 are based on the following description.
In June 2017, a cyberattack named NotPetya spread all over the world. Big companies like Marex, Merck, and
FedEx’s TNT Express lost a lot of money because of this attack.
18. Which company experienced the smallest percentage decrease in total revenue over a one month period
relative to its estimated total revenue loss over the same period?
19. Calculate the overall percentage decrease in revenue across all three companies in one month period
following the NotPetya attack.
20. Assuming the monthly revenue of Marex follows a Gaussian distribution with a standard deviation of 75,
(i) what is the probability that Marex’s revenue will be less than $850 million in the pre-attack scenario,
and (ii) what is the probability that Marex’s revenue will be more than $850 million in the post-attack
scenario?
z P (Z ≤ z)
-2 0.0227
-1 0.1586
0 0.5000
1 0.8413
2 0.9772
11
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination - Solutions
Part A - Answers
This is the only place that will be seen for grading part A. So carefully and clearly write the answers to
each question on the designated line below. Write only the final answers, do not show any intermediate work.
Illegible/unclear answers will not be considered.
• f is said to be surjective (or onto) if for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all y ∈ B
and g(f (x)) = x for all x ∈ A.
• For a matrix A, |A| denotes the determinant of A and AT denotes the transpose of A.
Part A - Questions
This section consists of some questions requiring a single answer and some multiple choice questions.
For questions that ask you to calculate a value, you will be assessed based on the answer you provide.
No explanation is required. In multiple choice questions, there may be multiple correct choices.
You have to select all the correct options and no incorrect option to get full marks. There
is no partial credit. Write the correct options / answer in the space provided on page 3.
Only page 3 will be seen for grading part A.
1. If P is an invertible matrix and A = P BP −1 , then which of the following statements are necessarily true?
(a) B = P −1 AP
(b) |A| = |B|
(c) A is invertible if and only if B is invertible
(d) B T = AT .
1 2 3 1 4 7 4 5 6 −1 2 3
2. Let A = 4 5 6 , B = 2 5 8 , C = 1 2 3 and D = 4 −5 6 .
7 8 9 3 6 9 7 8 9 7 8 −9
3. Let x = 3 1 2 . Which of the following statements are true?
(a) xT x is a 3 × 3 matrix
(b) xxT is a 3 × 3 matrix
(c) xxT is a 1 × 1 matrix
(d) xxT = xT x
2
4. A n × n matrix A is said to be symmetric if AT = A. Suppose A is an arbitrary 2 × 2 matrix. Then which
of the following matrices are symmetric (here 0 denotes the 2 × 2 matrix consisting of zeroes):
0 AT
A 0
(b) (d)
A 0 0 AT
Description for the following 3 questions: If Z is a continuous random variable which follows normal
distribution with mean = 0 and standard deviation = 1, then
Z a
exp{−z 2 /2}
P(Z ≤ a) = √ dz = Φ(a),
−∞ 2π
where Φ(a = −2) = 0.02, Φ(a = −1) = 0.16, Φ(a = 0) = 0.50, Φ(a = 1) = 0.84, and Φ(a = 2) = 0.98.
Note that X = µ + σZ follows normal distribution with mean µ and standard deviation σ. The length of
the life of an instrument produced by a machine has a normal distribution with a mean of 24 months and
standard deviation of 2 months.
5. The probability that an instrument produced by this machine will last less than 18 months is
Z 18
exp{−z 2 /2}
(a) √ dz.
−∞ 2π
Z ∞
exp{−z 2 /2}
(b) √ dz.
18 2π
(c) is less than 0.02.
( )
1 x − 24 2
Z 18
1
(d) √ exp − dx.
−∞ 2π.22 2 2
6. The probability that an instrument produced by this machine will die between 18 and 24 months is
7. Out of a large number of instruments produced by this machine, the percentage of instruments that will
last more than 26 months approximately
Description for the following four questions: Given below is the time table for a trans-continental
train cutting across several time zones. All times given below are local time in respective cities. It is given
that the average speed between any two cities is the same for both way journeys.
3
local time local time local time local time
arrival departure City arrival departure
- 06:00 AM ↓ Zut 12:40 PM -
07:45 AM 07:50 AM ↓ Yag ↑ 10:50 AM 10:55 AM
09:40 AM 09:45 AM ↓ Xum ↑ 06:55 AM 07:00 AM
12:10 PM 12:15 PM ↓ Wip ↑ 02:25 AM 02:30 AM
02:45 PM 02:50 PM ↓ Vaq ↑ 11:50 PM 11:55 PM
04:05 PM 04:10 PM ↓ Uap ↑ 08:30 PM 08:35 PM
05:40 PM 05:45 PM ↓ Tix ↑ 04:55 PM 05:00 PM
07:40 PM 07:45 PM ↓ Sab ↑ 12:55 PM 01:00 PM
10:40 PM - Raz ↑ - 08:00 AM
8. Which of the following pairs of cities are in the same time zone?
9. Write down the total time taken in minutes by the train to go from Zut to Raz.
12. In an entrance examination with multiple choice questions, with each question having four options and
a single correct answer, suppose that only 20% candidates think they know the answer to one difficult
question and only half of them know it correctly and the other half get it wrong. The remaining candidates
pick one option out of the four randomly and tick the same. If a candidate has correctly answered the
question, what is the (conditional) probability that she knew the answer?
13. There are n songs segregated into 3 play lists. Assume that each play list has at least one song. The
number of ways of choosing three songs consisting of one song from each play list is:
n3
(A) > for all n
27
n3
(B) ≤ for all n
27
(C) n3 for all n
14. Consider the following functions defined from the interval (0, 1) to real numbers. Which of these functions
attain their maximum value in the interval (0, 1)?
1
(a) f (x) =
x(1 − x)
(b) g(x) = −(x − 0.75)2
πx
(c) u(x) = sin( )
2
4
(d) v(x) = x2 + 2x
15. A farmer owns 50 papaya trees. Each tree produces 600 papayas in a year. For each additional tree
planted in the orchard, the output of each tree (including the pre-existing ones) drops by 5 papayas. How
many trees should be added to the existing orchard in order to maximize the total production of papayas?
16. Let a, b be numbers between 1 and 2 and let c, d be numbers between 3 and 4. Let u = a−1 , v = b−1 , w =
c−1 and x = d−1 . Say which of the following inequalities are true:
17. In the code fragment below, start and end are integer values and square(x) is a function that returns
True if x is a perfect square and False otherwise.
i := 0;
j := 0;
k := 0;
for m in [start,start+1, ...,end]{
if (square(m)=True){
i := i + m*m;
k := k + m*m;
}else{
j := j + m*2;
k := k + m*2;
}
}
At the end of the loop, which of the following are correct statements about the relationship between i, j
and k?
18. Given the following definition of the function foo, what does foo(1037,2) return? Note that a//b denotes
the quotient (integer part) of a ÷ b, for integers a and b. For instance 7//3 is 2.
function foo(n,d){
x := 0;
while (n >= 1) {
x := x+1;
n := n//d;
}
5
return(x);
}
19. A very special island is inhabited only by knights and knaves. Knights always tell the truth, and knaves
always lie. You meet three inhabitants: Ramesh, Bharat and Menaka. Ramesh claims, “Bharat is a
knave.” Bharat says, “Menaka and I are both knights or both knaves.” Menaka claims that Bharat is a
knave.
Which of the following are correct?
20. There are 7 switches on a switchboard, some of which are on and some of which are off. In one move, you
pick any 2 switches and toggle each of them—if the switch you pick is currently off, you turn it on, if it
is on, you turn it off. Your aim is to execute a sequence of moves and turn all 7 switches on. For which
of the following initial configurations is this possible? Each configuration lists the initial positions of the
7 switches in sequence, from switch 1 to switch 7.
(a) (off,on,on,on,on,off,on)
(b) (off,on,on,on,off,on,off)
(c) (off,on,off,off,on,off,on)
(d) (off,on,off,off,off,on,off)
6
Part B
For questions in part (B), you have to write your answer with a short explanation in the space provided below
the question. For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr ,
n P , n! etc.
r
f : N × N 7→ N
2. Suppose A, B and C are m × m matrices. What does the following algorithm compute? (Here A(i, j)
denotes the (i.j)th entry of matrix A.)
for i = 1 to m
for j = 1 to m
for k = 1 to m
C(i, j) = A(i, k) ∗ B(k, j) + C(i, j)
end
end
end
Solution: Overwrites C with AB + C.
1 1 0
3. Find A10 where A is the matrix 0 1 1 . Justify your answer.
0 0 1
1 10 45
Solution: 0 1 10 .
0 0 1
1 n n(n − 1)/2
In general, An = 0 1 n
0 0 1
4. In computing, a floating point operation (flop) is any one of the following operations performed by a
computer: addition, subtraction, multiplication, division. For example, the dot product of two vectors
(u, v, w) · (x, y, z) = ux + vy + wz involves 3 multiplications and 2 additions, a total of 5 flops.
Calculate the exact number of flops required computing C = AB for two 5 × 5 matrices A and B using
X 5
a direct implementation of cij = aik bkj . How does this number change if both the matrices are upper
k=1
triangular?
Solution: Computing each entry of the product matrix requires 5 multiplications and 4 additions, i.e. a
total of 9 flops. Since there are 25 entries to be computed, a total of 25 × 9 = 225 flops is required.
If the matrices are upper triangular, then the product matrix is upper triangular too, so that only 15
entries are computed. Also, the number of flops required per entry is reduced. For example, the number of
computations required for the first row is (5 + 4) + (4 + 3) + (3 + 2) + (2 + 1) + 1 = 9 + 7 + 5 + 3 + 1 = 25,
while for the second row 7 + 5 + 3 + 1 = 16 computations are required. The total number of computations
required is 55.
5. A function f from the set A to itself is said to have a fixed point if f (i) = i for some i in A. Suppose A is
the set {a, b, c, d}. Find the number of bijective functions from the set A to itself having no fixed point.
Solution: # bijections with exactly 4 fixed points equals 1 (the identity);
# bijections with exactly 3 fixed points equals 0, since 3 fixed points would imply the fourth one is also
fixed;
# bijections with exactly 2 fixed points equals 42 = 6 : choose the two points to be fixed, and don’t fix the
other two;
# bijections with exactly 1 fixed point equals 41 × 2 = 8 : choose one point to be fixed, for each such
choice the remaining 3 elements can be permuted in 2 ways without introducing new fixed points.
Thus the required number equals 4! − (1 + 6 + 8) = 24 − 15 = 9.
6. A 4-digit number is represented as abcd i.e. a × 103 + b × 102 + c × 10 + d, where a 6= 0. Suppose the
number dcba, obtained by reversing the digits of abcd, is 9 times abcd. Find the number abcd.
Solution: a must be ≤ 1, for else abcd ≥ 2000, but 2000 × 9 = 18000, while dcba has to be a 4-digit
number; since a 6= 0, thus a must be 1. Then d must be 9; if b ≥ 2, then abcd × 9 = 12c9 × 9 ≥ 10, 000,
so b must be ≤ 1. Consider the 2 cases:
(a) b = 1: in this case, 11c9 × 9 = 9c11 implies 9c + 8 has unit digit 1, so 9c has unit digit 3, so c = 7
and abcd = 1179, but 1179 × 9 6= 9711. So b = 1 does not give a solution;
(b) b = 0: in this case c = 8 and abcd = 1089 works.
P(at least one def ault) = 1 − P(N one of the debtors def ault)
= 1 − P(X = 0)
= 1 −200 C0 p0 (1 − p)200−0 = 1 − (1 − p)200
9. For the situation in the previous problem, what is the expected number defaults?
Solution: X ∼ Binomial(200, p)
1
E(X) = np = 200 × 100 =2
10. Suppose the bank earns 10% of the loan amount for every loan that is repaid. If the person defaults on
his/her credit then the bank loses the entire loan amount. What is the expected revenue of the bank from
a loan of Rs. 100,000?
Solution: If debtor repay the loan then the bank earns Rs 10,000. But the chance that the debtor will
repay the loan
99
10, 000 P(repay loan) = 1 − p = 100
revenue = 1
−100, 000 P(def ault) = p = 100
The expected revenue of the bank from every Rs 100,000 is 10000 ∗ 0.99 + (−100000) ∗ 0.01 = 8900.
Description for the following four questions:
An ice-cream company mainly operates in the five southern states of India. The pie chart shows the
breakdown of revenues (in percentages) for the ice cream company over the last summer. The bar chart
shows the detail of breakdown for strawberry flavor by states in lakhs of rupees.
Lakhs of Rupees
Other
4% 20
12% 15
26%
Mint 10
Chocolate 16%
5
Chocolate Fudge
0
Tamil Nadu Kerala Karnataka Andhra Telengana
14. If you assume that the chocolate flavor and the strawberry flavor are sold in the same proportion across
the five states, then what are the sales of chocolate in Tamil Nadu, in lakhs of rupees? Solution: The
total revenue of chocolate sale is Rs 86.67 Lakh (from previous question). The distribution of the sales
of chocolate flavor by state is same as that of strawberry flavor. That is 20% of the chocolate sales are
coming from Tamil Nadu. That is
x 20
= ,
86.67 100
20×86.67
where x is the sale of chocolate in the state of Tamil Nadu. That is x = 100 = 17.334. The sale of
chocolate in the state of Tamil Nadu is Rs. 17.334 Lakh.
15. A square piece of paper ABCD of side length 1 is folded along the segment that connects the upper right
corner B and the midpoint Q of the left edge AD, as shown. What is the vertical distance between the
base edge (segment DC) and the point P (which was originally point A)?
A B
P
D C
Solution: Let P R be ⊥ to QD and P T be ⊥ to BC. The right-angled triangles QP R and P BT are
similar with BP = 1 and QP = 1/2, so that BT = 2RP and P T = 2QR. Also BT 2 + P T 2 = 1. Now
BT − QR = 1/2, so that 2BT − 2QR = 1, so P T = 2BT − 1. Substituting in BT 2 + P T 2 = 1 gives
BT = 4/5, so the required length is 1/5.
16. A boolean value is a value from the set {True,False}. A 3-ary boolean function is a function that takes
three boolean values as input and produces a boolean value as output. Let f and g be 3-ary boolean
functions. We say that f and g are neighbours if f and g agree on at least one input triple and disagree
on at least one input triple: that is, there exists a triple (x, y, z) such that f (x, y, z) = g(x, y, z) and a
triple (x0 , y 0 , z 0 ) such that f (x0 , y 0 , z 0 ) 6= g(x0 , y 0 , z 0 ).
Suppose we fix a 3-ary boolean function h. How many neighbours does h have?
Solution: 254.
Of the 8 possible input combinations of the three input variables, neighbours agree on 1 to 7 of them.
8 8 8
1 + 2 + · · · + 7 = 254. Or, observe that there are 256 3-ary boolean functions. The only non-
neighbours of h are h itself and the unique function that differs from h on all arguments, so 256 − 2 = 254
are neighbours.
Description for the following four questions:
A golf club has m members with serial numbers 1, 2 . . . , m. If members with serial numbers i and j are
friends, then A(i, j) = A(j, i) = 1, otherwise A(i, j) = A(j, i) = 0. By convention, A(i, i) = 0, i.e. a
person is not considered a friend of himself or herself. Let Ak (i, j) refer to the (i, j)th entry in the k th
power of the matrix A.
Suppose it is given that A9 (i, j) > 0 for all pairs i, j where 1 ≤ i, j ≤ m, A2 (1, 2) > 0 and A4 (1, 3) = 0.
Then which of the following are necessarily true? Give reasons.
19. m ≤ 9.
Solution: False - in the extreme case every one is friend with everyone else and then A9 (i, j) > 0 for all
i, j, 1 ≤ i, j ≤ m irrespective of m - say m can be 100.
20. m ≥ 6.
Solution: True - the smallest chain that links 1 and 3 has length 5 - otherwise A4 (1, 3) > 0- so there are
at least 6 members in the club.
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination
15th May 2019
D − −
Enter your Admit Card Number :
IMPORTANT INSTRUCTIONS
• This booklet has 9 printed sheets, including this cover page. Sheet 2 (page 1) contains space to answer
part A, sheets 3 to 5 contain eighteen questions in part A and sheets 6 to 9 contain eighteen questions in
part B.
– For questions in part (A), you only have to write your answer on the designated page on the appro-
priate line. For example, if the answer is parts (a) and (c), write only (a) and (c) on the line and
if the answer is 2781, write this number on the line.
– For questions in part (B), you have to write your answer with short explanation in the space provided
below the question.
– For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr ,
n P , n! etc.
r
• Part A will be used for screening. Part B will be graded only if you score a certain minimum in part
A. However your scores in both parts will be used while making the final decision.
Points Remarks
Part A
Part B
Total
B1 B2 B3 B4 B5 B6 B7 B8 B9 Total
B10 B11 B12 B13 B14 B15 B16 B17 B18 Total
Part A - Answers
This is the only place that will be seen for grading part A. So carefully and clearly write the
answers to each question on the designated line below. Write only the final answers, do not show any
intermediate work. Illegible/unclear answers will not be considered.
A1. c A10. a, b
A3. a, b, d A12. b
A4. b, c A13. c
A6. b A15. a, b, c
A7. b A16. a, c, d
A8. a A17. d
A9. a A18. a, c
1
Notation
• A function f from a set A to a set B is said to be injective (or one-to-one) if f (x) = f (y)
implies x = y for all x, y ∈ A;
• f is said to be surjective (or onto) if for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all
y ∈ B and g(f (x)) = x for all x ∈ A and then g is said to be inverse of f and is denoted by
f −1 .
• For a matrix A, |A| denotes the determinant of A and AT denotes the transpose of A.
Part A - Questions
This section consists of some questions requiring a single answer and some multiple choice
questions. For questions that ask you to calculate a value, you will be assessed based on the
answer you provide. No explanation is required. In multiple choice questions, there may be
multiple correct choices. You have to select all the correct options and no incorrect option
to get full marks. There is no partial credit. Write the correct options / answer in the space
provided on page 1. Only page 1 will be seen for grading part A.
(a) 2n
(b) 2n − 1
(c) 2n − 2
(d) 2n/2
(a) (AT )T = A;
(b) |AT | = |A|;
(c) (AB)T = AT B T ;
(d) (A + B)T = AT + B T .
3
1 1 1 5 5 5 3 0 0
4. Let A = 0 2 2 , B = 0 10 10 , C = 3 6 0 . Which of the following state-
0 0 3 0 0 15 3 6 9
ments are true?
5. Consider the polynomials p(x) = (5x2 + 6x + 1)(x + 1)(2x + 3) and q(x) = (5x2 − 9x − 2)(2x2 +
5x + 3). The set of common divisors of p(x) and q(x) is:
(a) {2x + 3, x + 1, 5x + 1}
(b) {2x + 3, x − 1, 5x + 1}
(c) {x + 3, 2x + 1, x − 2}
(d) {2x − 3, x + 1, 5x + 1}
7. We need to choose a team of 11 from a pool of 15 players and also select a captain. The number
of different ways this can be done is:
(a) 15
11
(b) 11 · 15
11
(c) 15 · 14 · 13 · 12 · 11 · 10 · 9 · 8 · 7 · 6 · 5
(d) (15 · 14 · 13 · 12 · 11 · 10 · 9 · 8 · 7 · 6 · 5) · 11
Solution: (b). There are (15 choose 11) ways to pick the team. After that, there are 11 ways
to choose the captain.
8. Consider the following Venn diagram. The universal set U is the set of all natural numbers
from 1 to 1000.
4
A B
The sets A, B, C contain integers in U that are multiples of 6, 7, 8 respectively. The number of
elements in the shaded region is:
(a) 12
(b) 15
(c) 16
(d) 17
Solution: 12, these are all multiples of 56 that are less than 1000 and are not divisible by 6.
9. In the code fragment below, start and end are integer values and prime(x) is a function that
returns True if x is a prime number and False otherwise.
i = 0;
j = 0;
k = 0;
for m = start to end {
if prime(m) == True {
i = i + 1;
# Statement 1
}else{
j = j - 1 ;
# Statement 2
}
}
We wish to maintain the invariant k == i - j after each iteration of the for loop. What
should we insert at Statement 1 and Statement 2?
Solution: (a). i+(-j) is the number of the times the loop is iterated, so increment k in both
branches of the if.
5
Description for the following two questions:
The following table gives the budget allocation (in Rupees Crores) to 5 different departments
and their quarterly expenditure for a particular year.
Department Allocation Q1 Q2 Q3 Q4
D1 240 25 60 70 45
D2 120 10 40 30 20
D3 200 30 40 60 20
D4 125 20 35 20 25
D5 180 40 20 60 30
10. As a percentage of total allocation, the maximum quarterly expenditure (in any quarter) was
shown by
(a) D2
(b) D5
(c) D1
(d) D3
11. Looking at the combined expenditure of all the five departments, which of the following gives
the correct order as far as expenditure in each quarter is concerned?
Solution: (b)
12. Three boxes are presented to you. At most one of them contains some gold. Each box has
printed on it a clue about its [Link] clues are:
Only one clue is true; the other two are false. Which box has the gold?
(a) Box 1
(b) Box 2
(c) Box 3
(d) None of them has the gold
Solution: (b). The statement on Box 1 is true and the other two are false. If the gold were in
Box 1, both Box 2 and Box 3 have true statements. If the gold were in Box 3, both Box 1 and
Box 2 have true statements. If no box has the gold, both Box 1 and Box 2 have true statements.
6
13. Abha and Vibha both have white and yellow handkerchieves. To distinguish them, their mother
has marked Abha’s handkerchieves with the letter A and Vibha’s handkerchieves with the letter
V. There are 8 white handkerchieves of which 3 belong to Abha, and 11 yellow handkerchieves
of which 4 belong to Abha. All 19 handkerchieves were packed together in a bag for a trip.
Their mother pulled out a handkerchief from the bag without looking and found it was marked
V. What is the probability that the handkerchief was yellow?
(a) 5/12
(b) 7/19
(c) 7/12
(d) 11/19
Solution: (c). Vibha has 12 handkerchiefs, 5 white and 7 yellow. So the probability a random
one marked V is yellow is 7/12.
14. We need to choose a team of 11 from a pool of 15 players and also select a captain. The number
of different ways this can be done is:
(a) 15
11
(b) 11 · 15
11
(c) 15 · 14 · 13 · 12 · 11 · 10 · 9 · 8 · 7 · 6 · 5
(d) (15 · 14 · 13 · 12 · 11 · 10 · 9 · 8 · 7 · 6 · 5) · 11
TO BE LEFT BLANK.
15. The sum of the diagonal elements of a matrix A is called the trace of A and is denoted by tr(A).
Which of the following statements about the trace are true?
16. An upper triangular matrix is a square matrix with all entries below the diagonal being zero.
Suppose A and B are upper triangular matrices. Which of the following statements are true?
7
where Φ(a = −2) = 0.02, Φ(a = −1.5) = 0.067, Φ(a = −1) = 0.16, Φ(a = −0.5) = 0.31,
Φ(a = 0) = 0.50, Φ(a = 0.5) = 0.69, Φ(a = 1) = 0.84, Φ(a = 1.5) = 0.933, and Φ(a = 2) = 0.98.
Note that X = µ + σZ follows Gaussian distribution with mean µ and standard deviation σ.
Suppose the score distribution of an exam has a Gaussian distribution with mean µ and standard
deviation σ. A candidate fails if she/he obtains less than 35% marks. However she/he must
obtain more that 80% marks in order to pass with distinction. The exam is taken by a group
of 225 students and the results are given in Table 1..
You may use the fact that the sample mean X̄ follows a Gaussian distribution with mean µ and
√
standard deviation σ/ n.
(a) The probability that the average score of the group of 225 students is less than 48 is 2%.
(b) The probability that the average score of the group of 225 students is less than 42.5 is
6.7%.
(c) The probability that the average score of the group of 225 students is greater than 49 is
more than 50%.
(d) The probability that the average score of the group of 225 students is greater than 57.5 is
more than 16%.
8
Part B
For questions in part (B), you have to write your answer with a short explanation in the space provided
below the question.
n For numerical answers, the following forms are acceptable: fractions, decimals,
n
symbolic e.g.: r , Pr , n! etc.
9
3. Suppose X is a continuous distribution with probability density function
f (x) = k(x − x2 ), 0 ≤ x ≤ 1,
where k is the normalizing constant. Find the value of k and the expected value of the distri-
bution. R1 R1
Solution: 0 k(x − x2 )dx = 1 => k 0 (x − x2 )dx = 1. Solve for k. The solution is
R1
k = 6. The mean is 6 0 x(x − x2 )dx = 1/2. Also the kernel (x − x2 ) can be expressed as
(x − x2 ) = x(1 − x) = x2−1 (1 − x)2−1 . This is kernel of Beta(2, 2) distribution, which has a
mean 1/2.
4. Four friends attending an opera leave their coats at the checkroom. When they return each one
is handed a coat that does not belong to her. In how many ways can this happen?
Solution: Answer : 9. First person can get a coat of anyone else, 3 ways. The person whose
coat went to the first one can get a coat in 3 ways and the other two get determined by the first
two allocations. Alternate: (Inclusion-Exclusion principle) Total number of permutations = 4!;
let ai be the number of ways in which the ith friend gets her own coat back. Then each ai = 6
(the remaining 3 coats are permuted). So number of ways in which exactly one person gets her
coat back equals 6× 41 = 24. Similarly, 2 friends get their own coats back in 2× 42 = 12 number
5. If the lines 2x + y = 2, −5x + 3y = 4 and ax + by = 1 are concurrent then prove that the line
9x − 10y = 1 passes through (a, b).
Note: This problem as stated is wrong. Its been changed to finding the correct intersection
point of the lines 2x + y = 2 and −5x + 3y = 4.
Solution: The intersection point of the lines 2x + y = 2 and −5x + 3y = 4 is (9, −10).
10
exp(x)
6. Let θ = loge (2). For −θ ≤ x ≤ θ, let f (x) = 1+exp(x) . Compute α and β where
7. Ani is training for the olympics with Usain Bolt. After a few days of training Usain challenges
Ani to catch him. Usain sets off running very slowly with a view to encourage Ani. He covers
70m the first minute, 100m the next minute, then 130m the minute afterwards and so on. Ani
is told to start 3 minutes later. Having trained hard he runs 100m the first minute, 150 m the
second Minute, then 200m and so on. Ani catches Usain at an integral multiple of a minute.
How many minutes did Ani run before catching up with Usain. What were their respective
speeds?
Solution: Let n be the number of minutes Ani requires to catch Usain.
so n(20 + 5n − 5) = (n + 3)[14 + 3n + 6]. So 15n + 5n2 = (n + 3)(3n + 20) = 3n2 + 29n + 60,
i.e. 2n2 − 14n − 60 = 0. So n = 10, i.e. 10 minutes after Ani has started. They cover 3.25 km
each.
8. A small circular fire is spreading with its radius increasing at the rate of 1.5 metres per minute.
When the radius of the fire is 5 metres, how fast is the burned area growing?
Solution: (Implicit differentiation) Area of the circle A = πr2 ; so
d d
(A) = πr2
dt dt
so that dA dr
dt = 2πr dt . So when r = 5, the burned area is growing at the rate of 2π(5)(1.5) = 47.13
square feet per minute.
11
9. Show that among any set of 7 distinct integers there must exist 2 integers whose sum or difference
is divisible by 10.
Solution: (Pigeonhole principle) Let the numbers be a1 , . . . , a7 . Suppose difference of no two
is divisible by 10, so ai 6≡ aj (mod10). Then the remainders ri obtained by dividing the numbers
ai by 10 are all distinct and can be collected into 6 groups: {0}, {5}, {1, 9}, {2, 8}, {3, 7}, {4, 6}.
When 7 distinct remainders are taken from these groups, at least two of them, say rl and rk , must
come from the same group, then their sum is 0 or 10. Then al +ak ≡ rl +rk (mod10) ≡ 0(mod10)
i.e. 10 divides the sum of al and ak .
10. Let p(x) be a polynomial with integer coefficients. Let n be a positive integer and suppose a
and b are two integers such that a ≡ b(mod n). Is it true that p(a) ≡ p(b)(mod n)? Justify
your answer.
Solution: (Modular arithmetic) Use that the sums, differences and products of congruences are
congruent (w.r.t. the same modulus).
11. A thin piece of metal of length 20 cm and width 16 cm is to be used to construct an open-topped
box. A square will be cut from each corner and the sides will be folded up. What size corner
should be cut so that the volume of the box is maximized?
Solution: (Maxima/minima) Volume V = l × w × h. When x inches are removed from
each corner, the length is reduced to 20 − 2x and width is reduced to 16 − 2x; in this case
V = (20 − 2x)(16 − 2x)x = 4x3 − 72x2 + 320x. V 0 (x) = 12x2 − 144x + 320, so that x equals
(approx.) either 2.94 or 9.06. x = 9.06 cannot be used because that would make the length of
the sheet negative. The second derivative test confirms that V is maximized when x = 2.94.
12
12. Let n, k be positive integers. The expansion of (x1 + · · · + xk )n is given by
X n!
(x1 + · · · + xk )n = xn1 xn2 . . . xnk k ,
n1 !n2 ! . . . nk ! 1 2
where the sum is taken over all sequences n1 , n2 , . . . , nk of non-negative integers such that
n1 + n2 + · · · + nk = n. What is the coefficient of x5 in the expansion of (1 + 3x + 2x2 )4 ?
4! 4!
Solution: The general term in the expansion is a!b!c! 1a (3x)b (2x2 )c = a!b!c! 3b 2c xb+2c , where
5
a + b + c = 4. The term x corresponds to b + 2c = 5. We want to find common non-
negative integer solutions of a + b + c = 4 and b + 2c = 5. Solving these for 0 ≤ a, b, c ≤ 4
gives 2 solutions: (a, b, c) = (1, 1, 2) and (a, b, c) = (0, 3, 1). Hence the coefficient of x5 is
4! 2 4! 3
1!1!2! 3.2 + 0!3!1! 3 .2 = 360.
14. A thief picks a wallet and starts running at a speed of 5 m/s with zero acceleration. In 5
seconds, a policewoman notices the alarm and starts following the thief with a speed of 3 m/s
with a uniform acceleration of 1 m/s2 . How many seconds will it take the policewoman to catch
the thief, assuming she follows the same path as that of the thief? (A body moving with initial
velocity v0 m/s and uniform acceleration a m/s2 will cover a distance of (at2 /2 + v0 t) meters
in t seconds.)
Solution: the policewoman will catch the thief for that value of t for which the distance covered
by her equals (or just exceeds) the distance covered by the thief. This amounts to solving a
2
quadratic equation in t: 5t = (t−5)
2 + 3(t − 5) i.e. t2 − 14t − 5 = 0. This has one positive
solution, namely t = 14.3 (approximately). Hence the answer is 14 seconds.
13
15. Consider the following pseudocode for a function that operates on an N element array
A[1], A[2], . . . , A[N ] of integers.
(a) Explain what effect the function has on the input array A.
Solution: This function sorts the array in ascending order. In each iteration of the inner
loop, position identifies the location of the smallest value from A[i] to A[N]. After the
loop, this value is swapped into position A[i]. (This is a standard naive sorting algorithm
called selection sort.)
(b) If N = 100, how many times is the comparison A[j] < A[position] checked?
Solution: In the first iteration, the comparison happens 99 times. In the second iteration,
it happens 98 times. Overall, the comparison is checked 99 + 98 + · · · + 1 times, which adds
up to (99 × 100)/2 = 4950 times.
14
Description for next three questions:
The break-up of the colour of cars sold by an Indian company in a given year is provided in
the pie-chart, see the Figure (1). The bar chart shows the number of grey coloured cars sold in
different cities, see the Figure (2).
Solution:Number of grey cars sold in the year is 2250. This is 18% of total number of cars
sold in that year. So number of total cars sold in the year is 2250 ∗ 100/18 = 12500. Since
the number of blue color cars sold in that year is 14%, the number of blue cars sold were
12500 ∗ 14/100 = 1750.
17. If the proportion of grey cars sold in Delhi is the same as the proportion of red cars sold in
Delhi, how many red cars were sold in Delhi?
Solution: Total cars sold in the year is 12500, and 16% of them were red color cars. So the
number of sold red color was 2000. The share of grey color cars from Delhi was (180/2250)∗100 =
8%. If the same percentage of red colors were from Delhi, the number would be 2000 ∗ (8/100) =
160.
15
Figure 2: The number of grey cars sold in cities.
18. 12% of all cars were sold in Chennai. What is the largest possible percentage of brown cars sold
in Chennai, rounded off to the nearest integer?
Solution: The total number of cars sold was 12500 and 12% of them are from Chennai. So the
number of cars sold from Chennai is 12500∗(12/100) = 1500. On the other hand, the number of
brown cars sold was 12500∗0.12 = 1500. Since 400 grey cars were sold from Chennai, the largest
number of brown cars from Chennai is 1500 − 400 = 1100. So the largest possible percentage of
brown cars sold in Chennai is (1100/1500)100 = 73.33%.
16
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination 2020 - Solutions
Part A - Answers
• f is said to be surjective (or onto) if for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all
y ∈ B and g(f (x)) = x for all x ∈ A and then g is said to be inverse of f and is denoted by f −1 .
• For a matrix A, |A| denotes the determinant of A and AT denotes the transpose of A.
Part A - Solutions
This section consists of some questions requiring a single answer and some multiple choice
questions. For questions that ask you to calculate a value, you will be assessed based on the
answer you provide. No explanation is required. In multiple choice questions, there may be
multiple correct choices. You have to select all the correct options and no incorrect option to get
full marks. There is no partial credit. Write the correct options / answer in the space provided
on page 1. Only page 1 will be seen for grading part A.
f(x, y)
{
if (y != 0)
return (x * f(x, y-1));
else
return 1;
}
What is f(6,3)?
(a) 243
(b) 729
(c) 125
(d) 216
Solution: (d) is correct. This code computes xy . f(6,3) will compute 63 which is 216.
2
0 0 0 0 15 5 4 3 2 1
0 0 0 13 14
9 8 7 6 0
A=
0 0 10 11 12
and B=
12 11 10 0 0 .
0 6 7 8 9 14 13 0 0 0
1 2 3 4 5 15 0 0 0 0
3. Consider the following program. Assume that all variables are integers. Note that x%y computes
the remainder after dividing x by y. The division is an integer division. For example, 1/3 will
return zero while 10/3 will return 3.
g(n)
{
result = 0;
i = 1;
repeat until (n == 0)
{
remainder = n%2;
n = n / 2;
result = result + (remainder * i);
i = i * 10;
}
return result;
}
What is g(25)?
(a) 11001
(b) 10011
(c) 11011
(d) 10101
3
Solution: (a) is correct. This code converts any given integer to its binary repre-
sentation.25 is 11001 in binary.
Note: This question had a minor typographical error in the actual exam paper. This has been
taken into account when evaluating the question.
5. As per the data released by the US Department of Health, Education and Welfare, the number
of Ph.D. degrees conferred in Earth Sciences from the year 1948 to 1954 is as given in Table 5.
Year Degrees
1948 57
1949 88
1950 125
1951 135
1952 126
1953 146
1954 141
Based on the average of all available three year moving averages of annual growth rate, and the
number of degrees in 1954, what will be the (approximate) predicted number of degrees in earth
sciences in 2020? Note that a moving average or a rolling average is an average of a subset of
data points. Choose the best answer.
(a) 900
(b) 9,000
(c) 9,00,000
(d) 90,00,000
4
Solution: (c) is correct. First, we compute the Annual Growth Rate (AGR). Then,
we could compute the three year moving averages of AGR. Our calculations should
result in the moving averages as shown in Table 1. Note that the moving averages
average to 14.23. Starting with 141 in 1954, at a growth rate of 14.23%, we will
have 141 * (1 + 14.23/100)6 6 = 9,19,412.8. However, you may approximate to save
some time. For instance, the rule of 72 suggests that at a rate of 14%, the number
of Ph.D.s will double in approximately (72/14) 5 years. Therefore we have (1954)
150, (1959) 300, (1964) 600... and so on till (2019) 12,28,000. Hence, 9 Lakhs is the
closest answer.
Year Ph.D.s Annual Growth Rate Moving Avg
1948 57
1949 88 54.39
1950 125 42.05
1951 135 8 34.81
1952 126 -6.67 14.46
1953 146 15.87 5.74
1954 141 -3.42 1.93
Avg 14.23
6. Suppose that A is an n×n matrix with n = 10 and b is an n×1 vector. Suppose that the equation
Ax = b for an n × 1 vector does not admit any solution. Which of the following conclusions can
be drawn from the given information?
Solution: All we can conclude is that (a) and (c) are true, for otherwise Ax = b has
solution for all b. That (b) is false can be seen by taking A = (aij ) with a11 = a21 = 1,
a12 = a22 = 2 and the rest of the entries as 0; b = (bi ) with b1 = 3 and b2 = 6 and the
rest of bj ’s to be 0. Now Ax = b does not admit a solution, but x1 = 1 and x2 = 2
and rest of the xj ’s equal to 0 is a solution to AT x = b. In the same example, taking
c1 = 5 and c2 = 6 and rest of the entries as 0, we see that Ax = c also does not admit
a solution but b and c are linearly independent.
(a) Number of students who scored A grade in Algebra is higher than the number of students
who scored A grade in Calculus.
(b) Percentage of students who scored A or B in algebra is lower than the percentage of students
who scored A or B in calculus.
5
(c) Calculus is easier than algebra.
(d) Average percentage of students scoring A grade considering this data, is 12%.
Solution: (d) is correct. We do not have the total number of students enrolled in
Algebra and Calculus. Hence, we cannot conclude that A graders count in Algebra
is higher. 54% students scored A or B in Algebra. Only 40% scored A or B in
Calculus. Hence the second option is also false. Nothing in the question tells that
calculus is easier than algebra. In fact, the calculus distribution has a heavier tail.
Moreover, the data distribution does not mention that the same students over the
same semester took both classes. Hence, it would be inappropriate to compare the
difficulty of these courses. The final option is indeed true. The average percent of
students is (16 + 8)/2 = 12.
8. Let A = ((aij )) be a 7 × 7 matrix with ai,i+1 = 1 for 1 ≤ i ≤ 6, a7,1 = 1 and all the other elements
of the matrix are zero. Which of the following statements are true?
(a) |A| = 1
(b) trace(A) = 0
(c) A−1 = A
(d) A7 = I, where I is the identity matrix
6
9. Let A and B be events such that P (A) = 0.4, P (B) = 0.5 and P (A ∪ B) = 0.7. Which of the
following are true? (For sets A, B, A∆B = (Ac ∩ B) ∪ (A ∩ B c )).
(a) A and B are mutually exclusive
(b) A and B are independent
(c) P (A∆B) = 0.1
(d) P (Ac ∪ B c ) = 0.8
Solution : (b) and (d) are correct. (a) is False, for if it were true, P (A ∪ B) = P (A) +
P (B) = 0.9. (b) is true since P (A∩B) = P (A)+P (B)−P (A∪B) = 0.2 = P (A)∗P (B). Here,
P (A∆B) = P ((Ac ∩B)∪(A∩B c )) = P (Ac ∩B)+P (A∩B c )) which, by independence, equals
0.6∗0.5+0.4∗0.5 = 0.5. (d) P (Ac ∪B c ) = P (Ac )+P (B c )−P (Ac ∩B c ) = 0.6+0.5−0.6×0.5 = 0.8.
α
E(X) = =4
β
and
α α 1 1
V(X) = 2
= 2 =⇒ . = 2 =⇒ 4 = 2 =⇒ β = 2
β β β β
α α
E(X) = = 4 =⇒ = 4 =⇒ α = 8
β 2
Hence (b) is correct and (a) is wrong.
Now
α α α 1+α
V(X) = E(X 2 ) − [E(X)]2 =⇒ 2
= E(X 2 ) − [ ]2 =⇒ E(X 2 ) = ( )
β β β β
Hence, (c) is correct.
8 1+8
E(X 2 ) = ( ) = 18
2 2
Hence (d) is correct.
7
11. Out of a large number of cars produced by the automaker, the percentage of batteries that will
last for more than 8 years is
(a) "Z #
8
β α −βx α−1
e x dx × 100%.
0 Γ(α)
(b) " #
8
β α −βx α−1
Z
1− e x dx × 100%.
0 Γ(α)
(c) "Z #
∞
xβ α −βx α−1
e x dx × 100%.
8 Γ(α)
(d) "Z #
8
xβ α −βx α−1
e x dx × 100%.
0 Γ(α)
(a) 49
(b) 204
(c) 203
(d) 140
8
13. It is mid-semester exam week at CMI and first-year students from both [Link]. Data Science
(DS) and [Link]. Computer Science (CS) have their exams scheduled for Monday from 10:00am
to 1:00pm in Lecture Hall 1. The first row in Lecture Hall 1 has six seats. In how many different
ways can three [Link]. DS students—Anish, Binish and Finish—and three [Link]. CS students—
Ramesh, Suresh, and Ragesh—be seated in this row, in such a way that two students from the
same course do not sit next to each other?
(a) 36
(b) 48
(c) 72
(d) 96
Solution: (c) is correct. Suppose the first seat is occupied by a CS student. Then
there are three choices for who this student could be. The second seat must be
occupied by a DS student, and there are three choices for this. The third seat must
be occupied by a CS student, and there are two choices for this. The fourth seat
must be occupied by a DS student, and there are two choices for this. The last two
occupants are fixed, so there is one choice for these. In total there are 3 * 3 * 2 *
2 = 36 ways of seating the students if the first seat is occupied by a CS student.
Symmetrically, there are 36 (other) ways of seating the students if the first seat is
occupied by a DS student. In total, there are 72 ways of seating these students.
14. Suppose you roll two six-sided fair dice with faces numbered from 1 to 6 and take the sum of the
two numbers that turn up. What is the probability that:
• the sum is 12;
• the sum is 12, given that the sum is even;
• the sum is 12, given that the sum is an even number greater than 4?
1 1 1
(a) 36 , 18 , and 12 , respectively
1 1 1
(b) 36 , 18 , and 14 , respectively
1 1 1
(c) 36 , 16 , and 14 , respectively
1 1 1
(d) 36 , 16 , and 12 , respectively
(a) There are 36 outcomes (the first die can turn up anything from 1 to 6, and so
can the second die) of which exactly one sums up to 12. So the first probability
is 1/36.
(b) (This requires writing out the outcomes which add up to an even number.)
There are 18 outcomes which sum up to an even number (For any number that
turns up on the first die, three numbers on the second die give an even sum.),
of which exactly one sums up to 12. So the probability is 1/18.
(c) (The list of outcomes from part 2 comes in handy here.) There are 14 outcomes
which sum up to an even number larger than 4 (One outcome if the first die
turns up 1, two outcomes each if the first die turns up 2 or 3, and three outcomes
each if the first die turns up 4, 5, or 6.), of which exactly one sums up to 12.
So the probability is 1/14.
9
15. Let f (x) be a real-valued function all of whose derivatives exist. Recall that a point x0 in the
domain is called an inflection point of f (x) if the second derivative f 00 (x) changes sign at x0 .
x5 x4
Given the function f (x) = − + 3x + 1, which of the following statements are true?
20 2
(a) x0 = 0 is not an inflection point.
(b) x0 = 6 is the only inflection point.
(c) x0 = 0 and x0 = 6, both are inflection points.
(d) The function does not have an inflection point.
Solution: (b) is correct. The point of this question is to check if the concept of
inflection point is understood; the given function will have one inflection point, but
also points where second derivative is zero but is not an inflection point. Here
4
f 0 (x) = x4 − 2x3 + 3 and f 00 (x) = x2 (x − 6), so f 00 (x) vanishes at 0 and 6; but only 6 is an
000 000
inflection point since f (0) = 0 while f (6) 6= 0.
Solution: (d) is correct. If |r| ≥ 21 then the series on the right does not converge as
the nth term does not go to 0, while if |r| < 12 , this is a geometric series and the sum
is given by the LHS.
18. The sum and product of the roots of the polynomial 9x2 + 171x − 81 are, respectively:
10
(a) −19 and −9
(b) 19 and 9
(c) −9 and 19
(d) 9 and −19
Note: This question had a minor typographical error in the actual exam paper. This has been
taken into account when evaluating the question.
19. Choose the conclusions that follow logically from the statements given below.
i Nobody who really appreciates [Link] fails to subscribe to his YouTube channel.
ii Owls are hopelessly ignorant of music.
iii No one who is hopelessly ignorant of music ever subscribes to [Link]’s YouTube
channel.
(a) Anyone who subscribes to [Link]’s YouTube channel is hopelessly ignorant of music.
(b) Owls don’t really appreciate [Link].
(c) Owls are not really appreciated by [Link].
(d) Anyone who really appreciates [Link] is not hopelessly ignorant of music.
(a) ex ≥ (1 + x) for x ≥ 0
(b) ex ≤ (1 + x) for x < 0
(c) ln(x) < (1 + x) for x > 0
(d) ex < x2 for all real numbers x
11
Solution: (a) and (c) are true.
There are many ways to answer this. For example, using the second derivative
test. Let f (x) = ex − 1 − x using the second derivative test we see that x = 0 is
the global minimum. Hence, f (x) ≥ 0 (in fact) for all real values of x. If one sets
g(x) = 1 + x − ln(x) then x = 1 is the global minima and g(x) ≥ 2 for x > 0. One could
also appeal to the Taylor expansion; for x ≥ 0 we have ex = 1 + x + · · · .
12
Part B
For questions in part (B), you have to write your answer with a short explanation in the space provided
below the question.
n For numerical answers, the following forms are acceptable: fractions, decimals,
n
symbolic e.g.: r , Pr , n! etc.
1. For any string str, length(str) returns the length of the string, append(str1,str2) concate-
nates str1 with another string str2, and trim(str) removes any spaces that exist at the end of
the string str. The function reverse(str, i, j) reverses the part of the string from position
i to position j. Assume that position 0 refers to the first character in the string. What does the
following pseudo-code do?
trim(str);
return str;
}
Solution: This pseudo-code reverses a sentence word by word. For example, if the
input string is “I love India”, the output is “India love I”.
0 −1
2. Consider the matrix A = . Find An , in terms of n, for n ≥ 2.
1 0
2 −1 0 3 0 1 4 1 0
Solution: A = , A = , A = . So the next powers of A will
0 −1 −1 0 0 1
cycle through the above matrices. This means for n ≥ 1,
4n 1 0
A = , A4n+1 = A
0 1
4n+2 2 −1 0 4n+3 3 0 1
A =A = and A =A = .
0 −1 −1 0
13
3. The following graph shows the performance of students in an exam. The marks scored by every
student are a multiple of five. The j th -percentile u∗ for a discrete data x1 , x2 , . . . , xn is defined
as follows. Let x(1) , x(2) , . . . , x(n) be the ordering of the data in ascending order. Let t = j∗n
100 and
let k be an integer such that k ≤ t < (k + 1) and let s = t − k. Then u∗ = x(k) + s ∗ (x(k+1) − x(k) ).
Here, x(n+1) is defined to be x(n) .
Based on the information presented in the graph, answer the following questions.
4. In the figure shown below, the circle has diameter 5. Moreover, AB is parallel to DE. If DE = 3
and AB = 6, what is the area of triangle ABC?
Solution: The area of the triangle ABC is 24. CAB and CED are similar triangles.
Note that the triangle CED is a right triangle since the angle D spans the diameter.
The diameter CE of the circle forms the hypotenuse of the triangle CED. Therefore,
CD = 4. Since AB = 6 which is twice DE, BC scales up twice as CD as well.
Therefore, AB = 6, BC = 8 and area of triangle ABC = 12 (6)(8) = 24.
14
The following description holds for the two problems below.
A permutation σ is a bijection from the set [n] = {1, 2, . . . , n} to itself. We denote it using the
notation
1 2 ... n
,
σ(1) σ(2) . . . σ(n)
1 2 3
e.g. if n = 3 then denotes the permutation defined by σ(1) = 2, σ(2) = 3 and
2 3 1
σ(3) = 1. An inversion in σ is a pair (i, j) such that i < j but σ(i) > σ(j). The sign of
a permutation σ (denoted sgn(σ)) is defined to be (−1)inv(σ) , where inv(σ) denotes the total
number of inversions in σ. In the above example, there are 2 inversions corresponding to the
pairs (1, 3) and (2, 3) so that sgn(σ) = (−1)2 = 1.
For each permutation σ, define a matrix Aσ as follows:
(
1 if σ(i) = j
Aσ (i, j) =
0 otherwise
6. What are the determinants |Aσ | and |Aτ |? Can you relate these with the signs of permutations
σ and τ ?
Solution: |Aσ | = 1 and |Aτ | = −1. These can be found by observing that the matrices
are obtained from the 6 × 6 identity matrix by row/column exchanges. Aσ requires
even number of row exchanges, while Aτ requires odd number of row exchanges.
In general, for any permutation σ,
sgn(σ) = |Aσ |.
15
7. The case fatality rate (CFR) of a disease is the ratio of the number of deaths from the disease
to the total number of people diagnosed with the disease (“patients”), and is usually expressed
as a percentage. It has been reported that the CFR of Pandemic-20 among elderly people in
Gondwanaland is 20%. One way of treating a Pandemic-20 patient involves putting the patient
on a ventilator. It has been observed that in Gondwanaland, 60% of the elderly Pandemic-20
patients who survived the disease had been put on a ventilator, and 10% of the elderly Pandemic-
20 patients who died from the disease had been put on a ventilator. What is the probability
that an elderly Pandemic-20 patient in Gondwanaland survives the disease if they were put on a
ventilator as part of the treatment? Solution: Apply Bayes’ formula. Here
• P (A) = 0.80
• P (A0 ) = 0.20
• P (B | A) = 0.6
• P (B | A0 ) = 0.1
8. Owing to a defect in a certain machine which makes N95 masks, there is a 0.1% probability that
a mask it makes is not effective in preventing airborne viruses from being inhaled.
(a) What is the probability that the first 1000 masks that the machine produces are effective?
(You may leave your solutions as arithmetic expressions; there is no need to compute their
decimal representations.)
Solution: 0.9991000 . The probability that any one mask is not effective is 0.001.
The probability that any one mask is effective is thus 1 − 0.001 = 0.999. The
probability that the first 1000 (in fact, any 1000) masks are all effective is
0.9991000 .
(b) What is the probability that among the first one crore (107 ) masks that the machine pro-
7
duces, there is at least one mask which is not effective? Solution: 1 − (0.99910 ). By a
similar argument as for part (a), the probability that the first (or any set of ) 107
7
masks are all effective is 0.99910 . So the probability that at least one of these
7
masks is not effective is 1 − (0.99910 ).
9. The International Chess Federation is organizing an online chess tournament in which 20 of the
world’s top players will take part. Each player will play exactly one game against each other
16
player. The tournament is spread over three weeks; it starts at 9 a.m. on the Monday of Week 1
and ends at 6 p.m. on the Friday of Week 3. Note that before 9 a.m. on the Monday of Week 1
every player would have completed the same number of games in the tournament; namely, zero.
Also, after 6 p.m. on Friday in Week 3, every player would have completed the same number of
games in the tournament, namely, nineteen.
Prove that at any point in time between 9 a.m. on the Monday of Week 1 and 6 p.m. on the
Friday of Week 3, there are at least two players who would have completed the same number of
games in the tournament till that point.
Solution: At any point in time, the possible values for the number of games com-
pleted by any one player are {0, 1, 2, . . . , 19}. Pick an arbitrary point t in time. If a
player P1 has completed 19 games at time t, then the number of games completed
by any other player (say P2 ) at time t cannot be 0. This is because P1 must have
completed one game with P2 by time t, in order to have completed 19 games in total.
So both 0 and 19 cannot appear together in the list of actual values for the number
of games completed by all the players at time t.
Thus the count of players is 20, and the count of possible values for the number
of games completed by all the players at time t is at most 19. It follows from the
Pigeonhole Principle that there are at least two players who would have completed
the same number of games in the tournament till time t.
10. Your class has a textbook and a final exam. Let P, Q and R be the following propositions:
Translate the following assertions into propositional formulas using P, Q, R and the propositional
connectives ∧ (and ), ∨ (or ), ¬ (not) and ⇒ (implies).
(a) To get an A in the class, it is necessary for you to get an A on the final.
(b) You get an A on the final, but you don’t do every exercise in this book; nevertheless, you
get an A in this class.
Solution:
17
11. Two friends Amar and Prem wish to meet at a theme party between 5 p.m. and 6 p.m. (They
are said to meet if they are in the room at the same time or if one of them leaves as the other
enters.) Once they enter, they stay for exactly 20 minutes.
Solution:
(a) i. The latest time by which any one of them can enter is 5 : 40 p.m. ;
ii. If Amar and Prem are to meet, then their entry times can be separated by
at most an interval of 20 minutes.
(b) The sample space is the area of the square, each side of which represents 40
minutes. The event space is represented by the polygon in the square:
5:40 p.m.
5:20 p.m.
So the probability that the two will meet is the ratio of the two areas, which
equals: 34 or 0.75. (Assuming that each side is 2 units, the area of the square is
4 units and the area of the polygon inside it is [4 − (area of the two triangles)] =
[4 − 1] = 3 units.)
12. Let f be a continuous function on the closed interval [a, b] and differentiable on the open interval
(a, b), where a < b. It is known that there exists c in (a, b) such that
f (b) − f (a)
f 0 (c) = .
b−a
18
p √
6± 36 − 4.6.(−65) 6 ± 1596 6 ± 39.95
c= = = = 3.82 and − 2.83
2.6 12 12
So the final solution is √
6 + 1596
c= = 3.82
12
13. Let R be the set of all binary relations on the set {1, 2, 3}. Suppose a relation is chosen from R
at random. What is the probability that the chosen relation is symmetric?
n(n+1)
Solution: Number of symmetric binary relations on a set of size n is 2 2 . Total
number of binary relations are the relations that can be formed from the nine
elements of the set, {(1,1),(1,2),(1,3),(2,1),(2,2),(2,3),(3,1),(3,2),(3,3)} which is 29 .
6
Therefore, the answer is 229 = 1/8.
14. Peppa and her friends Suzy and Emily are making 3 masks: a knight mask, a pirate mask and
an elf mask. The one wearing the knight mask must always tell the truth, the one wearing the
pirate mask must always lie and the one wearing the elf mask could sometimes lie and sometimes
tell the truth. After making three masks, one of each kind, they all wear one each and make the
following statements:
15. For the function f (x) = ln(x)/x, show that the maximum value of y occurs when x = e. Use
this to show that xe < ex for all positive values of x.
Solution: f 0 (x) = 1−ln
x2
x
. Equating f 0 (x) to zero gives ln x = 1 which is true iff x = e.
Further this implies that for all x > 0, lnxx < f (e), i.e. lnxx < lnee i.e. e ln x < x i.e
ln(xe ) < ln(ex ). Since ln is an injective function, this implies xe < ex for x > 0.
16. Given the set of letters {a,b,c,d,e,f,g,h,i,j,k,l,m}, we can list out all permutations of
these letters in lexicographic (dictionary) order. The first three permutations in this list are
19
abcdefghijklm, abcdefghijkml and abcdefghijlkm and the last one is mlkjihgfedcba. What
permutations would appear immediately before and after the following one in this lexicographi-
cally ordered list of permutations?
bcjameflkihgd
17. Consider the following code, where A is an array of integers of size size(A) with values A[0] to
A[size(A)-1], and reverse(A,i,j) reverses the segment A[i] to A[j] if i <= j and has no
effect otherwise. For instance, if A = [0,1,2,3,4,5], then reverse(A,2,4) would modify A to
[0,1,4,3,2,5].
def mystery(A){
for j in [0,1,..,size(A)-1] {
p = j;
for i in [j,j+1,..,size(A)-1] {
if A[i] > A[p] {
p = i;
}
reverse(A,j,p);
}
}
}
(b) Suppose size(A) is 1000. How many times is the test How many times is the test A[i] >
A[p] executed?
Solution: 500,500 comparisons. For j ∈ {0, 1, . . . , 999}, in iteration j, there are
1000 − j comparisons made. So in all there are 1000 + · · · + 2 + 1 = (1000 × 1001)/2 =
500500 comparisons.
20
18. Eight students are to be seated around a circular table in a circular room. Two seatings are
regarded as defining the same arrangement if each student has the same student on his or her
right in both seatings: it does not matter which way they face. How many arrangements of
these 8 students are there with 2 chosen students, say student A and student B, always sitting
together?
Solution: The answer is 2 ∗ 6! = 1440. There are 6! ways to seat the remaining
students with B sitting to the left of A; similarly, there are 6! ways to seat the
remaining students with B sitting to the right of A.
19. Let f be a continuous bijection from closed unit interval [0, 1] onto itself. (Recall: intermediate
value theorem: Let f be a real valued continuous function on an interval [a, b]. Let c, d ∈ [a, b] be
such that f (c) < f (d) and α ∈ (f (c), f (d)) is an intermediate value. Then there exists y ∈ [a, b]
such that f (y) = α.)
(iv) Give an example of such a function wherein the fixed point is unique and an example of a
function with more than one fixed point.
Solution: An example: f (x) = 1 − x has unique fixed point x = 0.5. f (x) = x has
uncountably many fixed points!.
21
20. A multi-national conglomerate sells soap products for five different market segments, namely (i)
Women, (ii) Men, (iii) Kids, (iv) Sports, and (v) Luxury. The sales of these five segments (in
lakh number of packs) during 2012 and 2017 are shown in the following figure.
(a) By what percentage were the sales of the Women segment in 2017 more than the sales of
the Men segment in 2017?
Solution: Required percentage = 48−38 38 × 100 ≈ 26.32%
(b) During the period 2012-2017, which segment experienced the minimum rate of increase in
sales?
Solution:
•
• Rate of increase in women’s segment = 48−2020 × 100 ≈ 140% ;
38−6
• Rate of increase in men’s segment = 6 × 100 ≈ 533.33%,
• Rate of increase in kid’s segment = 29−15
15 × 100 ≈ 93.33%,
• Rate of increase in sports segment = 12−8
8 × 100 ≈ 50%,
10−5
• Rate of increase in luxury segment = 5 × 100 ≈ 100%.
So correct answer is sports.
22
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination 2021 - Solution
Part A - Answers
1
Multiple-choice questions
1. There are two longest subsequences, not necessarily contiguous, common to the strings “ARTIFICIAL” and
“INTELLIGENCE”. They are “IIC” and “TIC” which are of length three.
Consider two strings S1 = “CORONAVIRUS” and S2 = “SARSCOVID”. Let x be the length of a longest
common subsequence between S1 and S2 and let y be the number of such longest common subsequences of
length x between S1 and S2. What is x + 5y?
(a) 13
(b) 15
(c) 14
(d) 16
Solution: (b) is correct. The two (y = 2) lcs sequences are “covi” and “rovi”. The length, x = 4. Therefore,
x + 5y = 4 + 5 ∗ 2 = 14.
(a) 1, − 1, 2, 2 + 3i
(b) 1 + i, 1 − i, 2, − 2
(c) 1, − 1 + i, 2, 2 + 3i
(d) 1 + i, − 1 + i, 2, − 2
Solution: (b) is correct. (a), (c) and (d) are wrong because complex roots can appear only in conjugate
pairs.
(a) 23
(b) 17
(c) -17
(d) 35
Solution: (a) is correct. This code computes the maximum subarray sum which is 5 + 10 + 8 = 23.
2
4. A student has an average score of 80 from her first four Mathematics tests, and 88 from her first five
Physics tests. How much must she score in her upcoming tests to raise her average score in Mathematics
and Physics to 82 and 89, respectively?
(a) She should score 92 in Mathematics and 100 in Physics in the next tests.
(b) She should score 86 in Mathematics and 90 in Physics in the next tests.
(c) She should score 88 in Mathematics and 92 in Physics in the next tests.
(d) She should score 90 in Mathematics and 94 in Physics in the next tests.
Solution: (d) is correct. The average of her first four scores in Mathematics is sum of the scores on the
tests divided by 4. Since the average of first four test is 80, the sum of the four score is 80 × 4 = 320. Suppose
the score of her 5th Math test is x, the sum of the 5 Math scores is 320 + x, hence
320 + x
= 82.
5
Solving for x, we find x = 90, so she needs a 90 on her fifth test to raise her average of Mathematics to 82.
Similarly, the sum of five Physics score 88 × 5 = 440. Suppose the score of her 6th Physics test is y, the sum
of 6 Physics score would be 440 + y, hence
440 + y
= 89.
6
Solving for y, we find y = 94, so she needs a 94 on her sixth Physics test to raise her average to 89.
5. A binary tree starts with a single root node at the top of the tree. Each node can have either a left child or
a right child, or both, or neither. The children of a node are drawn below it, connected by edges. Here are
the five possible binary trees with three nodes.
Note that the directions left and right of the children matter. In the second tree, the root has a left child
that has a left child, while, in the fourth tree, the root has a left child that has a right child, and so on.
How many different binary trees can be constructed with four nodes?
(a) 3
(b) 5
(c) 14
(d) 30
Solution: (c) is correct. T (n) = (2n)!/(n + 1)!n! binary trees can be constructed with n unlabeled nodes.
So, T (4) = 8!/5!4! = 14.
3
Here, a^b represents the bitwise Exclusive OR function over variables a and b. For example, 3^4 = 7 and
9^5 = 12. The truth table for the Exclusive OR function is provided for your reference.
a b a^b
0 0 0
0 1 1
1 0 1
1 1 0
(a) 0
(b) 2
(c) 3
(d) 7
Solution: (d) is correct. This code finds the only unique value (if any) among duplicates in this array. 7
will be returned.
7. Fifteen telephones are received at a service center. Of these, 5 are mobile, 6 are cordless, and 4 are wired.
These 15 phones are randomly numbered from 1 to 15 to establish the order in which they are serviced.
Which of the following statement(s) is/are correct?
(a) The probability that among the first 3 serviced, the first and third are mobile and the second is not, is
5 × 10 × 4
.
15 × 14 × 13
1
(b) The probability that the first four serviced are all the wired phones, is 15 .
4
(c) The probability
that after servicing ten of these phones, only one of the three types remain to be
6
5
serviced, is 15 .
5
5 6 4
2 + 2 + 2
(d) The probability that two phones of each type are among the first six serviced, is 15
.
6
Solution:
(a) is correct.
(b) is correct.
(c) is wrong. The probability that after servicing ten of these phones, only one of the three types, remain to
6 5
+
be serviced is following: The 5 to be serviced are either mobile or cordless. So the probability is 5 15 5
5
5 6 4
2 2 2
(d) is wrong. The probability that two phones of each type are among the first six serviced is 15
6
4
(b) For any three real numbers x, y, z,
|x − z| ≤ |x − y| + |y − z|
(d) is correct. Suppose n = 1, then 13 − 1 = 0, i.e., 0 is divisible by 3. Therefore, the statement is true for
n = 1. Let us assume the statement is true for n = k, i.e., k 3 − k = 3x. Now, we need to prove that if the
statement is true for n = k then it is also true for n = k + 1,
The expression is the product of the three consecutive integers (n − 1), n, (n + 1). One of these three must
be divisible by 3.
10. Let A, B be n × n matrices. Which of the following properties of A and B are preserved under matrix
multiplication?
Solution: (a) and (c) are preserved under matrix multiplication, (b) and (d) are not.
5
11. The proportion of visitors to an e-commerce website in a week who would purchase a product follows the
beta distribution with the probability density function
Γ(α + β) α−1
f (x) = x (1 − x)β−1 , 0<x<1
Γ(α)Γ(β)
where Γ is the gamma function, α > 0, β > 0 and (α + β) > 2. The mean and mode of the beta distribution
α α−1
are E(X) = α+β and Mode(X) = α+β−2 . From historical data the mean and mode of the proportion of
1 1
buyers are estimated as 4 and 5 respectively. Which of the following statements is/are correct?
(a) α = 3 and β = 9
(b) The probability that in a given week the proportion of visitors who buy the product is between 10%
and 20% is given by
Z 0.2 Z 0.1
Γ(α + β) α−1 β−1 α−1 β−1
x (1 − x) dx − x (1 − x) dx
Γ(α)Γ(β) 0 0
(d) The probability that in a given week the proportion of visitors who buy the product is less than 20%
is given by Z 1
Γ(α + β) α
1− x (1 − x)β dx
0.2 Γ(α)Γ(β)
α 1
=
α+β 4
4α = α + β (1)
α−1 1
=
α+β−2 5
α−1 1
From (1) =
4α − 2 5
5α − 5 = 4α − 2
α = 3
6
(d) is wrong. The chance that on a given week the proportion of visitor would be less than 20% is
Z 1
Γ(α + β) α−1
1− x (1 − x)β−1 dx
0.2 Γ(α)Γ(β)
12. There are 1010 functions from {1, 2, . . . , 10} to {1, 2, . . . , 10}. Pick one such function f at random. Let p1
be the probability that f −1 (3) has exactly four elements, and p2 the probability that f −1 (2) has exactly six
elements. Which of the following is/are true?
(a) p1 > p2
(b) p1 < p2
(c) p1 = p2
(d) p1 = 34 p2
10 10
96 /c and p2 = 94 /c so p1 = 81p2 .
Solution: (a) and (d) are correct. p1 = 4 6
a 1 0
13. For a non-zero real number a, the inverse of J = 0 a 1 is
0 0 a
−1 −2 −3
a a a
(a) 0 a−1 a−2
0 0 a−1
−1
−a−2 a−3
a
(b) 0 a−1 −a−2
0 0 a−1
−1
a 1 0
(c) 0 a−1 1
0 0 a −1
−1 −2
a a 0
(d) 0 a−1 a−2
0 0 a−1
Solution: (b) is correct. One way to get the answer is row/column elimination on the augmented matrix
(J|I3×3 ), requires 4 simple steps this way.
7
Description for following two questions: In the 2019-2020 season of the English Premier League (EPL),
380 matches were played in a home and away format. The figure below describes the number of goals scored
by the home team and the away team against the number of matches played. For example, the home team
scored one goal in 125 matches.
(a) (b)
(a) The average number of goals scored by the home team over 380 matches is less than 1.5, and for away
teams are less than 1.
(b) In the whole season of the EPL, a total of 1034 goals were scored.
(c) The probability that away team failed to score any goal is 22.11%.
(d) The probability that home team scored more than 3 goals is 6.6%.
Solution: (a) is wrong. The average number of goals scored by home team over 380 matches are 576/380 ≈
1.515 > 1.5 Similarly, average number of goals scored by away team is 458/380 ≈ 1.21
(b) is correct. The total number of goal scored by home teams are 0+1×125+2×99+3×47+4×16+8+8×1 =
576 goals. Similarly, the total number of goal scored by away teams are 0 + 1 × 128 + 2 × 82 + 3 × 33 + 4 × 88 +
5 × 4 + 6 × 1 + 9 × 1 = 458 goals. So total number of goals scored by home and away team is 576 + 458 = 1034.
(c) is wrong. The probability that away team will fail to score any goal is 123
380 × 100 ≈ 32.37%.
(d) is correct. From Figure (part (a)) in 16 matches the home team score 4 goals, in 8 matches home team
scored 5 goals and in one match the home team scored 8 goals. So total 25 matches home team scored more
25
than 3 goals out of 380 matchs, i.e., 380 × 100 ≈ 6.6%.
(a) In more than 50% matches, the home team scored at most one goal.
(b) In more than 10% matches, the away team scored more than 2 goals
(c) In more than 15% matches, the home team scored three or more goals
(d) In more than 90% matches, the away team scored less than 3 goals
Solution: (a) is correct. The home team filed to score any goal in 84 matches and the home team scored 1
goal in 125 matches. So in 209 matched the home team scored one or less goal out of 380 matched played
during the season. Hence the statment is correct.
8
(b) is correct. There are 47 matches where the away team scored more than 2 goals (33+8+4+1+1=47),
which is 47/380 × 100 = 12.37%
(c) is correct. There are 72 (=47+16+8+1) matches where the home team score 3 or more goals out of 380
matches, that is (72/380) × 100 ≈ 18.95%
(d) is wrong. There are 333 (=123+128+82) matched where the away team scored less than 3 goals, that is
(333/380) × 100 = 87.63%
16. You are given a sequence of N digits. From this you can generate N -digit numbers as follows: Pick up each
digit in the given order, starting from the first one. Place it either to the left or to the right of the number
you have generated so far. For instance, if you start with the sequence [4, 3, 2, 5, 2], you can generate 53422
through the steps 4 → 34 → 342 → 5342 → 53422, and 22345 through the steps 4 → 34 → 234 → 2345 →
22345.
Which of the following sequences could have generated 51324?
(a) [2, 1, 3, 4, 5]
(b) [2, 3, 1, 5, 4]
(c) [2, 3, 4, 1, 5]
(d) [2, 4, 1, 3, 5]
• (a) From input [2, 1, 3, 4, 5], we cannot generate 132 from [2, 1, 3].
• (b) Input [2, 3, 1, 5, 4] : 2 → 32 → 132 → 5132 → 51324
• (c) Input [2, 3, 4, 1, 5] : 2 → 32 → 324 → 1324 → 51324
• (d) From input [2, 4, 1, 3, 5], we cannot insert 3 into the sequence 124 generated from [2, 4, 1].
Solution:
(a) True: checked easily by raising to appropriate powers; raise to 6 for the first part and raise to 12 for
the second part.
(b) False: 2r−1 r! ≥ (2r − 2)! is true only for r = 1, 2, 3; for r ≥ 4, the reverse inequality holds.
(c) True: Check it at k = 1, and observe that the phenomenon repeats with period 2π; there are other
intervals also where this is true, but we aren’t mentioning those.
(d) True: observe their graphs. On (0, 2), we have |x − 1| − 1 < ||x − 1| − 1|, while both functions agree on
values of x outside this interval.
9
Let A11 , A12, A21 , A22 , B11 , B12 , B21 , B22 be n × n matrices. Consider the 2n × 2n block matrices A =
18.
A11 A12 B11 B12
and B = . The product AB is given by:
A21 A22 B21 B22
A11 B11 A12 B12
(a)
A21 B21 A22 B22
A11 B21 + A12 B11 A11 B22 + A12 B21
(b)
A21 B21 + A22 B11 A21 B22 + A22 B21
A11 (B11 + B21 ) A12 (B12 + B22 )
(c)
A21 (B11 + B21 ) A22 (B12 + B22 )
A11 B11 + A12 B21 A11 B12 + A12 B22
(d)
A21 B11 + A22 B21 A21 B12 + A22 B22
Solution: (d) is correct; block matrix multiplication works like regular matrix multiplication in this case.
19. Consider right angled triangles with integer side lengths a, b, c where c is the hypotenuse. Call a right angled
triangle special if a and b are odd integers. How many special right angled triangles exist?
(a) 23
(b) infinitely many
(c) 0
(d) 12
Solution: (c) is correct. The question is to identify all pairs of odd integers (a, b) such that a2 + b2 is a
square. Suppose a = 2k+1 and b = 2l+1 for some non-zero integers k, l. Then a2 +b2 = 4(k 2 +l2 )+4(k+l)2,
so that 2 is the remainder when a2 + b2 is divided by 4. On the other hand, any square when divided by 4
will leave remainder 0 or 1 (this can be easily checked by analyzing the even and odd integer cases; in other
words, there are no squares that are 2 modulo 4. Thus a2 + b2 cannot be a square for odd numbers a and b.
Thus there are no special right angled triangles.
20. Given a sequence of numbers [x1 , x2 , . . . , xn ], we say that xi is left-visible if each number in [x1 , x2 , . . . , xi−1 ]
is strictly smaller than xi . Similarly xi is right-visible if each number in [xi+1 , xi+2 , . . . , xn ] is strictly smaller
than xi . For instance, in the sequence [13, 37, 24, 55, 46], the numbers 13, 37, 55 are left-visible and 55, 46
are right-visible.
Suppose we construct a sequence from the set {17, 22, 38, 49, 53} such that 4 numbers are left-visible and 2
numbers are right-visible. In addition, we are told that 22 is at the second position from the left. What are
the possible numbers at the third and fifth positions?
10
Part (B) - Short-answer questions
For questions in part (B), you have to write your answer with a short explanation in the space provided for the
question in your answer sheet. If you need more space, you may continue on the pages provided for rough work.
Any such overflows must be clearly labeled.
x = answer ;
answer = ( answer * 10) + 1;
while ( x > 0) {
y = x % 10;
answer = ( answer * 10) + y ;
x = x // 10;
}
return ( answer );
}
Here,
2. Food delivery agents Aman, Boni, Chan, Dong and Eman were assessed on five parameters P1 to P5. They
received an integer rating between 1 and 5 for each parameter. None of them received the same rating in
four or more parameters. Everyone received a score of 1 in P2 or P5. All of them received the same rating
in at least two parameters. The partial information related to the ratings are given in the table below.
Name P1 P2 P3 P4 P5
Aman 3
Boni 4
Chan 5
Dong 2
Eman 1
11
(a) What is the maximum average rating Boni could have achieved across all the five parameters?
(b) What is the minimum average rating Chan could have received across all the five parameters?
Solution: Boni would receive the best average if he scores either <4,1,5,5,5> or <4,5,5,5,1>. In either
case, the average is 4. To receive minimum average, Chan must have received three ones, one five and a
two. So Chan could have received either <1,1,5,1,2>, <1,1,5,2,1>, <1,2,5,1,1> or <2,1,5,1,1>. In
each case the average is 2.
function bar () {
A = [2016 , 2017 , 2018 , 2019 , 2020 , 2021 , 2022];
result = foo (A , 2021 , 7);
print ( result );
}
Here, a // b represents integer division. For example, 23 // 10 = 2. What will be printed when bar() is
executed?
Solution: This code performs binary iterative search for 2021 in the array A whose length is 7. This code
locates 2021 during the second iteration. Therefore c = 2. Since 2021 appears at index 5, m = 5. The output
will be 5 × 2 = 10.
4. The CMI MSc DS 2021 batch of 60 students is holding an online event to celebrate their joining CMI. Student
Aruni is in charge of organizing the musical section, and she sends out an online form where each student has
to mark whether they agree or decline to performing two activities during the event: singing, and playing a
musical instrument. Each student can mark one of four sets of choices: (i) agree to both singing and playing
an instrument, (ii) agree to sing and decline to play an instrument, (iii) agree to play an instrument and
decline to sing, or (iv) decline to do either activity.
All the students respond within the deadline, and Aruni sits down to tabulate the results so that she can
plan the musical events. She finds that thirty five students agreed to sing or play an instrument, of whom
twenty students agreed to do both.
How many students agreed to do exactly one activity, and how many declined to participate?
Solution: Twenty students agreed to do both activities, and fifteen declined to do exactly one activity. Can
be found by drawing a Venn diagram.
12
5. Show that every selection of 503 numbers from {1, 2, 3, . . . , 987} has two numbers with g.c.d. 1. Recall that
the g.c.d. of two positive integers x, y is the largest positive integer smaller than x, y which divides both x
and y.
Solution: Use pigeonhole principle. Pair numbers as (1, 2), (3, 4), . . . , (2n − 1, 2n). When we select n + 1
numbers we would certainly have to select a pair, thus consecutive numbers. In this case, we will have 494
‘holes’ (1, 2), . . . (985, 986), (987), and since we need to choose 503 numbers, at least 2 must come from the
same hole, so at least 2 numbers must be consecutive, thus having g.c.d. 1.
6. Let S be the sphere given by the equation x2 + y 2 + z 2 − 6x + 4y − 4z − 272 = 0. What are the centre and
radius of S? What is the minimum distance between S and the plane 2x + 2y + z = 214?
Solution: S = (x − 3)2 + (y + 2)2 + (z − 2)2 = 272 + 17 = 289. The centre of the sphere √ is (3,-2,2) and its
radius is 17. Distance of the centre from 2x + 2y + z = 214 is |2 ∗ 3 − 2 ∗ 2 + 2 ∗ 1 − 214/ 4 + 4 + 1| is 70.
So the closest point is at a distance of 53 from the sphere.
7. We draw two rows of n points with labels {1, 2, . . . , n}, as shown in the figure below.
1 2 3 n
1 2 3 n
We connect each point on the top with a point on the bottom at random, making sure that no two points
on the top are connected to the same point on the bottom. We say point j on the top is special if it gets
connected to point j below.
Let X be the number of special points. What is E(X), the expected value of X?
Solution: These are random permutations of [n]. Probability that i is mapped to i is 1/n. So if Xi denotes
the event that i connects to i, E(Xi ) = 1/n. So E(X) = n ∗ 1/n = 1.
8. Let Tn denote the set of all sequences over {0, 1, 2} of length n. If we pick an element x in Tn uniformly at
random what is the expected number of 1’s in x?
Solution Let X denote the number of
1’s in
x.X = X1 + X2 + . . . + Xn , where Xi is 1 if 1 the i-th position,
1 2 1 X n
else Xi is zero. Since E(Xi ) = 1 +0 = , so E(X) = E(Xi ) = .
3 3 3 3
n
X 1
9. What is the smallest possible value of , if the di ’s are constrained to be nonnegative real numbers
di + 1
i=1
n
X
and satisfy di = N .
i=1
n
X
Solution : If di > dj , then set d0i = d0j = (di + dj )/2. The constraint di = N continues to hold with
i=1
the new values of d0i , d0j . However 1
d0i +1
+ 1
d0j +1
< 1
di +1 + 1
dj +1 . So this reduces the objective function. The
minimum is therefore when all are equal, so each di = N/n. Harmonic mean. The objective function has
n
X n n2
value =
(N/n) + 1 (N + n)
i=1
13
a b c
10. Let A be the 3 × 3 real matrix d e f . Suppose xT Ax ≥ 0 for every x ∈ R3 . Then show that all of a, e
g h i
and i are non-negative.
1
Solution: Just take x to be the 3 standard basis vectors of R3 ; e.g. if x = 0 , then xT Ax = a, etc.
0
Understand what xT Ax does, and deduce that these choices of x will give the answer.
11. In the finale of the Indian Idol programme, Ladies Special, there are four women contestants — Arunima,
Priyamani, Razi and Shriya. The organisers send all participants a list of 7 songs, asking each one to pick
one song for the finale. All the four girls pick the same song, Pyar Hua Chupkese from the film 1942 A Love
Story. To resolve the tie, two days before the finale, the organisers prepare 7 sheets of paper and fold them.
Exactly one of the 7 songs from the list is written on each folded sheet and the folded sheets are identical
in all other aspects. First Arunima is asked to pick one sheet out of 7, then Priyamani is asked to pick one
sheet out of the remaining 6, then Razi is asked to pick one out of the remaining 5 and finally Shriya is asked
to pick one out of the remaining 4.
(a) What is the probability that the sheet chosen by Razi has the song Pyar Hua Chupkese?
(b) When Shriya is asked to choose a sheet, she argues that the three sheets chosen by the others should
be opened, and if Pyar Hua Chupkese is not chosen by anyone, she should be allowed to pick that song.
This is agreed to. What is the probability that Shriya gets to sing the song Pyar Hua Chupkese?
Solution:
(a) The number of ways in which Razi can choose the said song is same as counting the number of ways a
song
can be chosen if only 6 options are made
available to the others. So Arunima can choose a song in
6 5
1 ways, Priyamani can choose a song in 1 ways. So the total number of ways in which Razi chooses
Pyar Hua Chupkese is 30. The total number of choices is 7 × 6 × 5 = 210. Thus the required probability
30
is 210 = 17 .
(b) This is the probability that none of the earlier contestants chooses the song Pyar Hua Chupkese, which
6×5×4
can happen in 6 × 5 × 4 ways. So the required probability is 7×6×5 = 47 .
Description for following two questions: A Non-Banking Finance Corporation (NBFC) declares fixed
annual rates of simple interest on their auto and housing loans each year. The rates of interest offered by
the company differ from year to year depending on the variation in macro economic indicators like inflation,
RBI’s repo rate etc. The annual rates of interest offered by the company for the Auto and Housing sectors
over the years are shown in the figure.
12. In 2013, a customer took a housing loan and a car loan. The total loan amount was |60 lakhs. The interest
paid by the customer after one year was |7.36 lakhs. What was the housing loan amount?
Solution: Suppose |x lakhs was the housing loan amount in 2014, the amount of car loan in 2014 =|(60
- x) lakhs. Since the loan was only one year old so it must have been agreed upon at the rate of interest
prevalent in 2013, which (from the figure) was 14%. The rate of interest on the housing loan was 12%.
Total interest received from the loans after 1 year is:
= |[(12% of x) + 14% of (60 - x)] lakhs
14
2
= |[8.4 - 100 x] lakhs
Therefore
2
8.4 - 100 x = 7.36 =⇒ x = 52
13. In 2012, Customer A took a fixed interest auto loan of |5 lakh for 4 years, which meant he paid interest
according to the 2012 rate each year. Also in 2012, Customer B took a variable interest auto loan for |5
lakh for 4 years which meant his interest each year was calculated based on the prevailing interest rate for
that year. Which of them paid more interest over 4 years? How much more?
Solution: Customer A pays 4 × 12 = 48% interest over 4 years. Customer B pays 12 + 14 + 11 + 10 = 47%
interest over 4 years. So Customer A pays 1%, or |5000, more.
14. Let Y be a continuous random variable that takes values in [0, 1].
Determine c.
(b) Using g(y), find the probability that Y is greater than 0.8.
Solution: (a)
1 1 1 h y 3 i1 h y 4 i1 4−3
Z Z Z
2 2 1 1 1
y (1 − y)dy = y dy − y 3 dy = − = − = =
0 0 0 3 0 4 0 3 4 12 12
15
So the probability function is
g(y) = 12y 2 (1 − y), 0≤y≤1
(b) The probability is
Z 1 nh y 3 i1 h y 4 i1 o
2
P(Y > 0.8) = 12y (1 − y)dy = 12 −
0.8 3 0.8 4 0.8
n 1 0.83 1 0.84 o
= 12 − − −
3 3 4 4
≈ 12(0.16267 − 0.1476)
= 0.1808
15. The state government has decided to regulate the sale and distribution of solar power. There are multiple
suppliers and consumers, as described in the tables below. The supplier table lists the amount of electricity
generated by each supplier, in megawatts (MW), and the supplier’s selling price per MW. The consumer
table lists the amount of electricity required by each consumer, in MW, and the price the consumer will pay
per MW.
The government wishes to fix a uniform market price per MW for solar power. If this price is p, any seller
whose selling price is at most p will be willing to sell some or all of the electricity they generate at price p.
Similarly, any consumer who is willing to pay at least p can buy as much electricity as they need at price p,
upto their required quantity.
Find the value of p at which the maximum amount of solar power can be bought and sold on the market.
Solution: As the market price increases, the supply available for sale increases and the consumer demand
drops. Here are tables describing how supply and demand vary with market price.
From this, it is clear the optimum market price is 200. At this price, the supply available is 890 MW and
the demand is 860 MW so the volume of power bought and sold will be 860 MW. If the market price drops
to 199, the supply drops to 650 and if the market price increases to 201, the demand drops to 300.
16. (a) If a polynomial f (x) has roots r1 , r2 , . . . rn , what are the roots of the polynomial f (x + 1)?
(b) Let f be a polynomial of degree three. Set g(x) = f (x − 1). Assume none of the roots of f are −1.
What are the roots of the polynomial x3 g(1/x)?
16
Solution: h(x) = f (x + 1). Then h(r − 1) = f (r − 1 + 1) = f (r) = 0 for every root of f . So the roots of h
are r − 1, r a root of f .
The roots of g(x) are r + 1, where r is a root of f . Since −1 is not a root of f , none of the roots of g are
zero. Let h(x) = x3 ∗ g(1/x). If r is a root of g which is non zero, h(1/r) = (1/r)3 g(r) is zero. So the roots
of h(x) are 1/(r + 1) where r is a root of f .
ln x
18. (a) Consider the function f (x) = x . Find the critical point(s) of f and say whether f has a maximum or
minimum at that point.
(b) Prove that for integers a > b ≥ 3, we must have ab < ba .
Solution: Using the first and second derivatives it can be shown that f (x) has one critical point, x = e, at
which it attains its maximum (f 0 (x) = 1−ln
x2
x
and f 00 (x) = 2 lnxx−3
3 ). So for x < e, the function is increasing
and for x > e the function is decreasing. This implies the conclusion.
19. Recall that if h is a function from X to Y and g is a function from Y to Z then, g ◦ h is the function from
X to Z such that (g ◦ h)(x) = g(h(x)), for all x ∈ X.
Let S be the set of all functions f from {1, 2, 3, 4, 5, 6} to {1, 2, 3, 4, 5, 6} such that f ◦ f = f .
(a) Compute the number of functions f ∈ S whose range has three elements.
(b) What is the cardinality of S?
Solution: If y is an element in the range of f then f (y) = y since f is idempotent. Because if z maps to
y, y = f (z) = f (f (z)) = f (y).
Can pick 3 elements in the range of f in 63 ways. Now these elements have to go to themselves under
f since f ◦ f = f . . And the remaining 3 elements have to map to one of them. So the number of such
functions is 3 * 3 * 3 =27. So the total number of functions with range of size 3 is 63 ∗ 27.
20. A pinhole camera is placed between an object and a sensor. Recall that images from a pinhole camera are
inverted (see figure below.) Assume that the object lies on a plane and that the planes containing the object,
the plane containing the pinhole and the sensor/image plane are all parallel to each other.
17
¥¥É÷÷
Sensor
plane
I
pinhole
1¥
1
,
(a) Show that straight lines are projected to straight lines. In particular, show that if A, B, C are three
collinear points on an object, then their corresponding images a, b, c are also collinear.
(b) Suppose two identical objects M and N having height 60cm are placed before the pinhole camera at
distances 90cm and 120cm respectively. Suppose also that the distance between the pinhole and the
image plane is 30cm. What are the heights of their images after projection through the pinhole camera?
(a) Notice the pairs of similar triangles: 4AOB v 4aOb and 4BOC v 4bOc implies that ∠ABO = ∠abO
and ∠CBO = ∠cbO. SO
∠abO + ∠cbO = ∠ABO + ∠ABO = 180◦ .
Thus, a, b, c are collinear.
(b) Let D1 denote the distance between O and first object plane, and D2 denote the distance between O and
second object plane. Let d denote the distance between O and the image plane.
H D
In general, if H is the height of the object and h is the height of its image, then similarity gives = ,
h d
where D is the distance of the object plan from O.
From the given information we have:
H D1 90 H D2 120
= = = 3, and = = = 4.
h1 d 30 h2 d 30
H1 60 H2 60
So h1 = = = 20cm, and h2 = = = 15cm.
3 3 4 4
Thus, image of M has height 20cm and image of N has height 15cm.
Objects placed farther from the pinhole appear smaller in size.
18
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination 2022 – Solutions
Part A - Answers
Solution: Choices (a) and (c) are correct, and choices (b) and (d) are wrong. These follow from straight-
forward computation using standard formulas.
2. Consider the following code, in which A is an array indexed from 0 and n is the number of elements in A..
function foo (A , n ) {
L = 0;
R = n - 1;
while ( L <= R ) {
i = ceil (( L + R )/2);
if ( A [ i ] < i ) {
L = i + 1;
} else {
if ( A [ i ] > i ) {
R = i - 1;
} else {
return ( i );
}
}
}
return ( -1);
}
Here, ceil(x) returns the smallest integer bigger than or equal to the number x.
If A = [-5, -4, -3, -2, -1, 4, 6, 8, 10, 12], what will foo(A, 10) return?
(a) -5
(b) -1
(c) 4
(d) 6
Solution: Choice (d) is correct. Given a sorted array A with distinct integers and the length of A as
arguments, this function nds an index i such that A[i] = i, or returns -1 if there is no such index i.
Since there is exactly one such index, namely 6, this is what we get back.
Solution:
Choices (b) and (d) are correct, and choices (a) and (c) are wrong.
• (a) is wrong: This is a GP series. For |r| > 1 the limit is divergent.
(eix −e−ix ) (eix +e−ix )
• (b) is correct: Since e−ix = cos x − i sin x, we have sin x = 2i , and cos x = 2 .
• (c) is wrong:
∞
X
1 1 1 1
+ + + ··· =
1.2 2.3 3.4 n(n + 1)
n=1
X
n
1
= lim
n→∞ k(k + 1)
k=1
hX n
1 1 i
= lim −
n→∞ k k+1
k=1
h 1 1 1 1 1 i
= lim 1 − + − + · · · + −
n→∞ 2 2 3 n n+1
h 1 i
= lim 1 − = 1.
n→∞ n+1
Z π/6 " #π/6
1 3π π
• (d) is correct: 3 cos 3x ≥ 0 ∀x ∈ (0, π/6), and 3 cos 3x dx = 3 sin 3x = sin = sin = 1.
0 3 6 2
0
4. Let E and F be events such that P(E ∩ Fc ) = 0.2, P(F ∩ Ec ) = 0.3, P((E ∩ F)c ) = 0.7, where, for an event E, the
notation Ec denotes the complement of the event. Then we can conclude that
(a) P(E ∪ F) = 0.8.
(b) P(Ec ∩ Fc ) = 0.3.
(c) P(F) = 0.6.
(d) P(E) = 0.6.
Solution: Choices (a) and (c) are correct, and choices (b) and (d) are wrong. These follow from straight-
forward computation, e.g., by using a Venn diagram.
5. Let A, B be n × n invertible matrices of real numbers. Let C = I + AAT , D = I + BAAT BT . We can conclude
that
(a) (AB)−1 = (I + B−1 A−1 )
(b) (AB)−1 = A−1 B−1
(c) C = CT
(d) D = DT
Solution: Choices (c) and (d) are correct, and choices (a) and (b) are wrong. These follow by straight-
forward computation using standard properties of matrices.
6. A matrix C is said to be symmetric if CT = C. Which of the following is/are true? Let A, B be n × n matrices.
(a) If A is symmetric and invertible, then A−1 is also symmetric and invertible.
(b) If A and B are symmetric, then C = AB is also symmetric.
(c) If A and B are invertible, then C = AB is also invertible.
(d) If A and B are symmetric, then D = A + B is also symmetric.
Solution: Choices (a), (c) and (d) are correct, and choice (b) is wrong. These follow from standard
properties of matrices.
Solution: Choice (d) is correct, and choices (a), (b) and (c) are wrong:
• (a) is wrong: If A is all zeroes, then Ay = 0 for any vector y, and A is clearly not full rank.
• (b) is wrong: Let the rst m rows of A be identical to the m × m identity matrix, and let the
remaining rows be all zero. Then there is no such nonzero solution y.
• (c) is wrong: Consider
I5
.
0
This matrix has n = 6, m = 5, and row and column ranks both equal to 5.
• (d) is correct: The rank of A is the least such r.
8. Let n ≥ 5 be a natural number, let X = {x1 , x2 , ..., xn }, and let Y = {y1 , y2 }. Let F be the set of functions from
X to Y and G be the set of bijective functions from X to Y . Then
Solution: Choices (b) and (d) are correct, and choices (a) and (c) are wrong:
• (c) is wrong: Since X, Y have di erent cardinalities, there are no bijections from X to Y .
9. In order to select a debating team to represent a school, 7 students from class XII and 13 students from class
XI were shortlisted and were undergoing trials. The coach had to select a team of 5 students, out of which at
least two students should be from each class. One out of the 5 students was to be named as team leader, who
was to be from class XII. Two teams with the same members but di erent leaders are considered to be two
di erent teams. The number of di erent teams the coach can select is
7 13 7 13
(a) 2 × × + ×
2 3 3 2
7 13 7 13
(b) × + ×
2 3 3 2
7 13 7 13
(c) 2 × × +3× ×
2 3 3 2
7 13 7 13
(d) 3 × × +2× ×
2 3 3 2
Solution: Choice (c) is correct, and choices (a), (b) and (d) are wrong.
Any choice of team either has exactly 2 students from class XII and exactly 3 students from class XI, OR
it has exactly 3 students from class XII and exactly 2 students from class XI. The two terms in the sum
in choice (c) correspond to these two cases.
For each choice of k ∈ {2, 3} students from class XII, there are k ways of choosing the leader. This is the
leading term in each product in choice (c).
Here is an alternate derivation: There are 7 ways of selecting a leader. For each leader selected, we can
now pick either a single student from class XII or two students from class XII and the rest need to be from
class XI. To form a team by selecting a single non-leader student from class XII, there are 7 · 61 · 133
ways. To form a team by selecting exactly two non-leader class XII students, there are exactly 7 · 62 · 132
ways. The answer is the sum of these.
10. Which of the following plots correspond to a function whose derivative is continuous?
I. I
I Ciii)
t ( in
0 . I 0
I 1
Liii) ( ir)
12. A relation R on the set A = {a, b, c, d} is de ned by reading the columns of the following table from top to
bottom. If a column in the table reads (x, y, 1) it means x is related to y in R. If a column in the table reads
(x, y, 0) it means x is not related to y.
a b c d a b c d a b c d a b c d
a a a a b b b b c c c c d d d d
0 0 1 0 1 0 0 0 1 1 0 1 0 0 1 0
For instance, from the fth column we have, (a, b) ∈ R, and from the second we have (b, a) ∈/ R.
Another relation S on the set A is de ned as: for any x, y ∈ A, the pair (x, y) is in S if and only if there exists
z ∈ A such that both (x, z) ∈ R and (z, y) ∈ R hold.
Which of the following pairs are in S?
(a) (a, a)
(b) (b, b)
(c) (c, c)
(d) (d, d)
Solution:
Choices (a), (c), and (d) are correct, and choice (b) is wrong:
13. We say that a subset S of a nite set U is large if |S| > |U \ S|. Here U \ S denotes the elements of U which
are not in S and the notation |T | denotes the number of elements in a set T . Let x be the number of large
subsets of the set X = {1, 2, . . . , 10}, and let y be the number of large subsets of Y = {1, 2, . . . , 9}. Which of the
following is true?
(a) x = 260, y = 256
(b) x = 386, y = 256
(c) x = 386, y = 130
(d) x = 512, y = 256.
14. A ternary tree starts with a single root node at the top of the tree. Each node in the tree can have up to three
nodes as its children. No node in the tree is the child of two di erent nodes. A node which has no children is
called a leaf node.
The children of a node are drawn below it, connected by edges. The level of a node v in the ternary tree is
the number of edges in the (unique) path from the root node to v. Thus, for instance, the root node is at
level 0, and each child of the root node is at level 1.
A complete ternary tree is a ternary tree in which (i) each non-leaf node has exactly three children, and (ii)
all leaf nodes are at the same level. This latter level is called the height of the complete ternary tree. The
completeNternary trees of heights 0, 1, and 2, respectively are shown in the gure below, where we use the
symbol to denote a node:
N N N
N N N
N N N
N N N N N N N N N
(c) 310 −1
2
(d) 310 +1
2
Solution: Choice (c) is correct: the number of nodes is the value of the sum 1 + 31 + 32 + . . . + 39 .
Choices (a), (b), (d) are wrong.
15. Which of the following expressions take integral values for all integers n > 100 ?
(a) 3n −1
2
(b) 4n −1
2
(c) 4n −1
3
(d) 5n −1
2
Solution:
Choices (a), (c) and (d) are correct, and choice (b) is wrong:
16. At a conference attended by 1235 people, some attendees shake hands with other attendees. As a part of the
local COVID-19 tracing protocol the organizers ask each attendee to note down the number of other attendees
with whom they shook hands. Let N be the sum of all the numbers noted down by the attendees. That is, N
is the sum, taken over all attendees, of the number of other attendees with whom they shook hands. Which
of the following is guaranteed to be true about N ?
(a) N is always a multiple of 1235
(b) N is always a multiple of 2
(c) N is always a multiple of 3
(d) N is always a multiple of 5
Solution: The only correct choice is (b): Each handshake adds 2 to N , so N must be an even number.
17. Let n be a positive integer and let k be a positive integer which is greater than 1. Then n can be represented
as
n = nt kt + nt−1 kt−1 + · · · + n1 k + n0
for a unique set of positive integers n0 , . . . nt . This expression is called the representation of n in base k and is
denoted by (nt nt−1 . . . n0 )k . For example the integer 264 expressed in base 3 is represented as (1 0 0 2 1 0)3
because 264 = 1 × 35 + 2 × 32 + 1 × 3.
Which of the following expressions represent the integer (1 1 0 1 1 1 1 0)2 ?
(a) (1 1 0 0)8
(b) (1 3 4 2)5
(c) (4 3 2)7
(d) (2 2 0 2 0)3
Solution: Choices (b) and (d) are correct, and choices (a) and (c) are wrong. The given integer, in
decimal notation, is 222.
18. There are two villages X and Y in a faraway land. It is known that each person from village X always tells the
truth, and that each person from village Y always lies.
You meet three people A, B, C who are from these villages. You are told that A and B are from the same
village. A says, \If B is from village X, then I am from village Y ". Now C says, \If I am from village X, then
2 + 2 = 4".
What can you infer about the villages to which A, B, and C belong?
(a) A, B are from village X and C is from village Y .
(b) All three of them are from village Y .
(c) A, B are from village Y and C is from village X.
(d) The given information is insucient to infer the villages to which A, B, C belong.
19. A stick is xed on the ground at an angle of 60 degrees as shown in Figure 1. The part of the stick which is
above the ground|which is the part that is shown in Figure 1|has a length of 10 metres. At a certain time
T1 during the day, the sun is directly overhead at this location and its rays strike the ground at an angle of
90 degrees. This is shown in Figure 2. At a certain later time T2 the sun's rays strike the ground at an angle
of 60 degrees as shown in Figure 3. While Figures 2 and 3 show only the sun's rays for the sake of clarity, the
stick is present at this location at times T1 and T2 .
Sunrays Sunrays
Stick
60° 60°
90°
What are the lengths of the shadows of the stick at times T1 and T2 , respectively?
√ √
(a) 5 3 metres and 10 3 metres
√
(b) 5 metres and 10 3 metres
(c) 5 metres and 10 metres
√
(d) 5 3 metres and 10 metres
20. A park in Chennai has walkways as depicted in the gure. The straight path from A to B is 100 metres long.
The curved part is a semicircle whose centre coincides with the midpoint of line segment AB.
A B
A woman and her dog take a walk in this park, both starting from point A at the same time. The woman
takes the straight path from A to B, while the dog goes around the semicircular path. The woman and the
dog both reach point B at the same time. If the woman takes 10 minutes to reach from point A to point B,
which of the following statements about the woman's and dog's walks is/are true?
(a) The average speed of the woman's walk is between 0.15ms−1 and 0.17ms−1
(b) The average speed of the woman's walk is between 0.17ms−1 and 0.20ms−1
(c) The average speed of the dog's walk is between 0.25ms−1 and 0.27ms−1
(d) The average speed of the dog's walk is between 0.27ms−1 and 0.30ms−1
Solution: Choices (a) and (d) are correct, and choices (b) and (c) are wrong:
• The length of the semicircular path is π × 50m ≈ 157m, with π ≈ 3.14. The average speed of the
dog's walk is thus ≈ 157m
600s ≈ 0.262ms .
−1
Note that to get these answers right it is enough to compute that 0.15 < 16 < 0.20, and 0.25 < 160
600 < 0.3.
Part (B) – Short-answer questions
For questions in part (B), you have to write your answer with a short explanation in the space provided
for the question in your answer sheet. If you need more space, you may continue on the pages provided for
rough work. Any such over ows must be clearly labeled.
1. There are three di erent approaches that climbers can take to reach the summit of Mount Cherno , namely,
Approach-I, Approach-II, and Approach-III. Each attempt at the summit uses exactly one of these
approaches. From climbers' logs it is known that Approach-I is used in 40% of the attempts, and Approach-
II and Approach-III are each used in 30% of the attempts. From the same logs it is also known that in 10%
of the attempts which used Approach-I the climber lost their way and had to be rescued. Similarly, 15%
of the attempts that used Approach-II and 17% of the attempts which used Approach-III resulted in the
climber losing their way.
It is reported one day that climber Chebyshev has lost her way. What is the probability that she took
Approach-II?
Solution: 0.045
0.136 ≈ 0.3308824 .
The following information is given in the description:
• P(Approach-I) = 0.4 • P(Approach-II) = 0.3 • P(Approach-III) = 0.3
• P(lost | Approach-I) = 0.1 • P(lost | Approach-II) = 0.15 • P(lost | Approach-III) = 0.17
Now,
P(lost) = P(lost | Approach-I)P(Approach-I)
+ P(lost | Approach-II)P(Approach-II)
+ P(lost | Approach-III)P(Approach-III)
Hence
0.15 ∗ 0.3
P(Approach-II | lost) = ≈ 0.3308824
0.136
2. Express the total service outage caused by all the three servers, as a percentage of the total duration over
which the information was collected.
Solution: 2.8% .
The following information is given in the description:
3. What is the expected number of hours of service outage in an year (365 days)?
4. As part of their due diligence, a potential customer of Dasholytics picks a random point in time during the
year and checks the status of the dashboard. What is the probability that the customer nds that there was
a service outage at this point in time, and that Server 1 was the server responsible for serving data at that
time?
Solution: 0.004 .
The chance of service outage due to Server 1 is
P(Outage and Server 1) = P(Outage | Server 1) × P(Server 1) = 0.01 × 0.4 = 0.004,
5. An alert that a service outage has been caused by one of the three servers, was sent out to the Dasholyltics
team. What is the probability that this outage was caused by Server 1?
6. In a question paper, there are 5 questions in part A, 4 in part B, and 3 in part C. In how many ways can a
candidate make up her choice, if she has to select 3 from part A, 2 from part B, and 2 from part C?
Solution: 180
The possible number of selections is
5 4 3 5×4×3 4×3 3×2
× × = × × = 180.
3 2 2 3×2 2×1 2×1
Let X be a random variable with mean E(X) = µPand variance Var(X) = σ2 . Let X1 , X2 , . . . , Xn be n
independently sampled values of X, and let X = n1 i Xi be the sample mean. The central limit theorem
states that if the sample size n is large enough then X approximately follows the normal distribution with
mean µ and variance σ2 /n. That is, X ≈ N(µ, σ2 /n). This in turn implies that
√
− µ)
n(X
Y= ≈ N(0, 1).
σ
Let Z be a random variable that follows the normal distribution with mean 0 and variance 1. For any real
number a let Φ(a) = P(Z < a) be the probability that Z takes values smaller than a. Then
Za 2
e−u /2
Φ(a) = P(Z < a) = √ du.
−∞ 2π
For solving the next two problems you may assume the following approximations: Φ(−2) = 0.02, Φ(−1) =
0.16, Φ(0) = 0.5, Φ(1) = 0.84, Φ(2) = 0.98.
The weekly number of sales S at a certain car dealership is known to follow a probability distribution with
mean E(X) = 10 and variance Var(X) = 144. A performance audit picks a random sample of 36 weekly sales
gures S1 , S2 , . . . , S36 from the last two years. They nd that the sample mean is 10 and the sample variance
is 144. Use this information to answer the next two questions. You may assume that n = 36 is a large enough
sample size.
7. (a) What is the probability that the average number of sales in a week will be more than 8?
Solution: 0.84
Note that X ≈ N(10, 2), where µ = 10, σ = 12, and n = 36. So we have
√36(X
− 10)
√
36(8 − 10)
> 8) = P
P(X >
12 12
6 × −2
= P Z> = P(Z > −1) = 1 − P(Z < −1)
12
= 1 − Φ(−1) = 1 − 0.16 = 0.84.
(b) What is the total number of sales over the 36 weeks which were sampled?
Solution: 360
The average sales per week is 10, i.e., X = 10 . Since the number of weeks n = 36, the total sales is
P
Xi = n × X = 36 × 10 = 360.
8. Check if the following statement(s) are correct. Brie y explain your reasons.
(a) The probability that the average number of sales in a week will be more than 8 but less than 14 is
Z 14
1 u−10 2
√ e−0.5( 12
)
du
8 12 2π
(b) The probability that a salesperson would be able to sell ten or more products in a week is 50%.
Solution: Correct.
It is given that the weekly average sales follows a normal distribution with mean 10. The probability
that the weekly average sales is at least the mean, is half.
9. Two particles move in opposite directions around a circular track. The rst moves at a constant speed of 10
m/s. The speed of the second increases at a constant rate of 2 m/s every second. The particles are at the
same position A at time 0, with the second particle being momentarily at rest at t = 0. We are told that
the second meeting of these particles after time 0 takes place at the point A. We assume that the particles
magically cross each other the rst time they meet with no change in their instantaneous velocities. Given
this information:
(a) What is the circumference of the track?
(b) At what time did the particles meet for the rst time after time 0?
√ √ √
Solution: ( 125 − 5) = (5 5 − 5) = 5 ∗ ( 5 − 1) ≈ 6.18 seconds.
√ √
Solving 100 = 10t1 + t21 , we get t1 = (−10 + 500)/2 = 5 ∗ ( 5 − 1).
10. Words are formed using the characters 0 and 1. The length of a word is the number of characters in it. We
say there is a path from word x to word y if starting from the word x you can get the word y by applying the
following sequence of transformation rules nitely many times in any order.
• Replacing an occurrence of the string 101 by a 0.
• Replacing an occurrence of the string 010 by a 1.
• Replacing a 0 by a 101.
• Replacing a 1 by by a 010.
If there is a path from word x to word y we say x and y are equivalent or that they are in the same equivalence
class. For example the four letter word 1011 is equivalent to the two letter word 01, since the pre x 101 in
1011 can be replaced by a 0 to get 01.
We say x has a shorter description if there is a word of shorter length equivalent to it.
(a) State true or false: for any word x there is a unique shortest word in its equivalence class.
Solution: False.
E.g.: 1010 ≡ 11, and 1010 ≡ 00.
(b) How many three letter words are there in this language which have no shorter descriptions and which
are all in di erent equivalance classes?
11. You are given an 8 × 8 chessboard and a large supply of T -shaped tiles and square-shaped tiles of the kind
shown below.
Note that the squares in these two shaped tiles are of the same size as the black/white squares on the
chessboard.
We wish to cover the squares of the chess board using these tiles. Each square of the chessboard must be
occupied by exactly one square from a tile; we are not allowed to break the tiles.
(a) Is it possible to cover the chessboard with 16 T shaped tiles? Why?
Solution: Yes.
Greedy tiling will work for a 4 × 8 grid, by trial and error. Doing this twice will cover the entire chess
board.
(b) Is it possible to cover the chessboard with 15 T shaped tiles and one square tile? Why?
Solution: No.
Note that a square tile occupies two black and two white squares on the chessboard. So 15 square
tiles occupy 30 black and 30 white squares in total. There are two white and two black squares left
to cover. A T-shaped tile occupies either 3 black squares and a white square, or 3 white squares and
a black square. So we cannot cover the remaining four squares with a T-shaped tile.
12. To guard against login attempts by bots, Alphabet Bank of India uses a captcha challenge on their net banking
login page. The captcha text is a sequence of ve letters from the English alphabet.
(a) An early version of the captcha text consisted of a sequence of ve distinct letters picked uniformly at
random from the lower-case English alphabet, {a, b, c, . . . , z}. Two examples of such captcha text are:
qfhdk and smgft. An example of such captcha text which has its rst two letters in increasing alphabetical
order is: vxztr.
What is the probability that the captcha text generated in this way has the first two letters in
increasing alphabetical order, and why?
1
Solution: 2
One way to see this is as follows: construct a bijection between strings that have their rst two letters
in alphabetic order, and those which don't. That is: let xyZ be a captcha text, where x, y stand for
some one letter each, and Z stands for the remaining three letters. The bijection maps xyZ to yxZ,
and exactly one of these two strings has its rst two letters in alphabetical order. So the number of
captcha texts with the desired property is exactly half the total number of captcha texts.
(A solution which explicitly computes the fraction of favourable sequences over all possible sequences,
and evaluates to half, is also valid.)
(b) After a couple of years the bank noticed that some bots had become very good at cracking the captcha.
So they updated their software so that it now generates the captcha text by picking ve distinct letters
uniformly at random from the English alphabet, where the case of each letter can be either upper or
lower. That is, the letters are now picked from the set {a, b, c, . . . , z, A, B, C, . . . , Z}. Note that the same
letter does not appear in both lower and upper case in the same captcha text.
Two examples of the captcha text generated by this version are: QFhDk and sMgfT. Examples of such
captcha text with the rst two letters in increasing alphabetical order are: VxPTr and vXptR. Note that
the case of the letter does not matter when deciding the alphabetical order.
What is the probability that the captcha text generated in this way has the rst two letters in increasing
alphabetical order, and why?
1
Solution: 2
One way to see this is as follows: construct a bijection between strings that have their rst two letters
in alphabetic order, and those which don't. That is: let xyZ be a captcha text, where x, y stand for
some one letter each, and Z stands for the remaining three letters. The bijection maps xyZ to yxZ,
and exactly one of these two strings has its rst two letters in alphabetical order. So the number of
captcha texts with the desired property is exactly half the total number of captcha texts.
(A solution which explicitly computes the fraction of favourable sequences over all possible sequences,
and evaluates to half, is also valid.)
13. Among 40 bicycle gears, 28 are broken or rusted but not both, 6 are non-defective (i.e. neither rusted nor
broken), and the number of broken gears equals the number of rusted ones. How many gears are rusted?
Solution: 20
Let U = number of bicycle gears, B = number of broken gears, R = number of rusted gears. We are given
that |U| = 40, |B − R| |R − B| = 28, |B R| = 6 and |B| = |R|. So |B R| = 40 − 6 = 34, which implies
S S c S
14. Consider the following code, in which A and B are arrays indexed from 0 and lenA and lenB are the numbers
of elements in A and B, respectively.
function foo (A , B , lenA , lenB ) {
acc = 0;
for i = 0 to ( lenA - 1) {
acc = A [ i ]^ acc ;
}
print ( acc );
for i = 0 to ( lenB - 1) {
acc = B [ i ]^ acc ;
}
print ( acc );
}
Here, a^b represents the bitwise Exclusive OR function over variables a and b.
Given integers a and b, we write them in binary, padded by zeros to the left to make them of equal length.
We then apply Exclusive OR to these binary representations bitwise. The operation a^b denotes the in-
teger value obtained by performing bitwise Exclusive OR on the binary values of a and b. For example,
3^4 = 011^100 = 111 = 7, and 9^5 = 1001^0101 = 1100 = 12. The truth table for the Exclusive OR
function is provided.
a b a^b
0 0 0
0 1 1
1 0 1
1 1 0
Let A = [1, 3, 3, 5, 5] and B = [9, 5, 5, 3, 3, 1]. What are the two values printed by foo(A,B,5,6),
in order?
15. Consider the following code, in which A and B are arrays indexed from 0 and lenA and lenB are the numbers
of elements in A and B, respectively.
function foo (A , B , lenA , lenB ) {
sum = lenA + lenB ;
i = 0;
j = 0;
for t = 0 to ( sum - 1) {
if ( A [ i ] < B [ j ]) {
i = i + 1;
} else {
if ( A [ i ] > B [ j ]) {
j = j + 1;
} else {
return A [ i ];
}
}
}
return ( -1);
}
Let A = [2, 4, 6, 7, 8, 9, 10] and B = [1, 3, 5, 7, 9, 11, 13]. What does foo(A,B,7,7) return?
Solution: 7
Given (i) two positive integer arrays A and B, each sorted in non-decreasing order, and (ii) the lengths of
these two arrays as arguments, this function returns the smallest integer which is present in both A and B,
or −1 if there is no common element. Since the smallest common element is 7 for these arrays, the code
returns 7.
(An explanation that shows how the code runs on this particular input and returns the answer, is also
valid.)
16. Consider the following code, in which A is an integer array of length n indexed from 0, and x is an integer.
function foo (A ,x , n ) {
found = False ;
Here, randInt(0,n) returns an integer picked uniformly at random from the range {0, 1, . . . , (n − 1)}.
All integers present in array A are distinct, and integer x is present in array A. Suppose we make the call
foo(A,x,n). What is the expected number of times that the call randInd(0, n) is made from within this
call to foo(A,x,n)?
Solution: n
The probability of each call to randInd(0, n) succeeding (that is, returning an i such that A[i] == x)
is n1 . This is because there are exactly n elements in A, of which exactly one element is equal to x. So the
expected number of trials before one trial succeeds, is n.
17. A graph consists of a nite set of vertices, and edges between some (unordered) pairs of these vertices. The
graphs in this question have no loops (an edge between a vertex and itself) or multiple edges (more than one
edge between the same pair of vertices). A vertex v in a graph is said to be a global vertex if there is an edge
between v and every other vertex in the graph.
A graph G is constructed as follows: First, its vertex set is assigned to be the set {v1 , v2 , . . . , v10 }. Next,
between each pair of distinct vertices vi , vj , an edge is added with probability 12 .
(a) What is the probability that vertex v1 is a global vertex in graph G?
1
Solution: 29
All the 9 possible edges incident with v1 have to be added by the random process. The probability
of adding one of these edges is 12 . The description implies that edges are added independently of one
another. So the probability of adding all these 9 edges is 219 .
10
Solution: 29
From the previous question, the probability of each vertex being global is 219 . So the expected number
of global vertices among 10 such vertices is 10 × 219 .
Here is an alternative explanation, with more details: To each vertex, assign an indicator random
variable that takes the value 1 exactly when the vertex is a global vertex. The number of global
vertices is then the sum of these indicator random variables. The expected number of global vertices
is the expectation of this sum. By linearity of expectation, this in turn is the sum of the expectations
of the indicator random variables. The expectation of each indicator random variable is just the
probability that it takes the value 1. And this probability is 219 . So the sum of expectations is
10 × 219 .
18. The sum of two positive integers a and b is 48 and their least common multiple is 189. Find a and b.
Solution: a = 21 and b = 27
Let d denote the g.c.d. of a and b. Then there are integers m and n such that a = dm, b = dn and
g.c.d.(m, n) = 1. In that case dmn = 189 and d(m + n) = 48.
g.c.d.(m, n) = 1 implies g.c.d.(dmn, d(m + n)) = d, so d must be g.c.d.(189, 48) = 3. Then m + n = 24
and mn = 63. Together with the fact that g.c.d.(m, n) = 1, this implies that m = 7, n = 9. So a = 21
and b = 27.
19. Recall that for an n × n matrix A, det(A) = det(AT ). Here AT is the transpose of matrix A. An n × n matrix
A is said to be skew-symmetric if ai,j = −aj,i , where ai,j denotes the element in the ith row and jth column,
for all 1 ≤ i, j ≤ n and all elements are real.
(a) Is the following statement true or false? Why?
If n is odd, then the determinant of an n × n-skew symmetric matrix is 0.
Solution:
One such example:
0 1
A= .
−1 0
20. An object X is viewed from a camera placed at point C1 . The camera is then moved to the point C2 and X is
again viewed from this new position. Suppose H is the plane containing the points C1 and C2 . Let H ′ be a
plane parallel to H lying between the object X and the camera positions. Let f denote the distance between
H and H ′ . Let X1 , X2 be the points of intersection of H ′ with the line segments joining X with C1 and C2
respectively.
Let x1 be the distance between the reference axis L1 and X1 . Similarly let x2 be the distance between the
reference axis L2 and X2 . The axes L1 and L2 are both perpendicular to the camera plane H. The di erence
|x1 − x2 | is called the disparity in views. Find a formula for the depth z i.e. distance of the object from the
camera plane in terms of f, the distance b between the cameras, and the disparity.
• ✗
H
:¥ "
H
C
l
,
← b →
1
ti
Cz
:
↓ .
Z
b×f
Solution: z = |x1 −x2 |
Multiple-choice questions
1. Six children — Abhay, Bhavna, Charanjit, Divya, Enakshi and Farid — are
sitting, in that order, around a circular table at a birthday party, as shown on
the right. Each of them may be seated or standing.
They play a game, as follows. The birthday girl’s father calls out the initials
of a pair of children seated next to each other. The children whose initials are
called out then change their position from sitting to standing or vice versa.
Initially, all children are seated. Which of the following announcements will
result in an arrangement where Abhay and Enakshi are standing and the other
four children are seated?
(a) F A, DE, BC, CD, AB, F A
(b) AB, BC, DE, EF, EF, DE
(c) AB, CD, BC, EF, DE, EF
(d) AB, CD, F A, BC, AB, DE
Solution: (a) F A, DE, BC, CD, AB, F A and (c) AB, CD, BC, EF, DE, EF .
If a child’s name is called out an even number of times, the final position is the same as the initial position.
If it is called out an odd number of times, the final position is different from the initial position. We need
the parity of A and E to be odd and the rest to be even.
x4 + 1 x3 − x
f (x) = ; g(x) = .
x3 − 1 x3 + x
Which of the following is/are true?
Solution: FFTT.
(a) limx→1− f (x) = −∞ and limx→1+ f (x) = ∞, so f does not have a removable discontinuity at 1. So:
False.
(b) f is not continuous at x = 1. The function g is not defined at x = 0, so g is continuous at x = 0. So:
False.
(c) True, since x4 has a higher degree than x3 − 1.
(d) True, the range is between −1 and 1. Both g(x) < −1 and g(x) > 1 yield contradictions.
1
(a) n has to be even.
(b) 3 does not divide n
(c) 7 divides n
(d) 5 does not divide n
41
Solution: TFTT. The sum is 42 + n1 . Since this has to be an integer, n can only be 42.
4. Let a1 < a2 < a3 < a4 < . . . < . . . be a sequence of infinitely many positive integers which are in arithmetic
progression. Furthermore, suppose a2 , a4 , a8 are in geometric progression. Which of the following is/are
true?
(a) For every positive integer n, there is a triple of numbers ai < aj < ak which are in geometric progression
with ratio n, i.e. aj = ai n, ak = aj n.
(b) If i < j then ai divides aj .
(c) There are only finitely many n for which there are infinitely many triples i < j < k with ai , aj , ak in
arithmetic progression with common difference n.
(d) a10 , a30 , a90 are in geometric progression.
Solution: We have a, a + r, a + 2r, a + 3r and (a + 3r)2 = (a + r)(a + 7r). Therefore r = a and an = na. So
TFFT.
5. Let A be a 20 × 11 matrix with real entries. After performing some row operations on A, we get a matrix
B which has 12 nonzero rows. Which of the following is/are always true?
Solution: FFTT
(a) False. E.g.: Suppose A had 12 identical nonzero rows (and the rest all zeroes) to start with, and we
swapped two rows to get B, which also has exactly 12 nonzero rows. The rank of A is 1.
(b) False. Follows from the definition; “row or column operations do not change the rank”.
(c) True. Same reason as above; the null space is unchanged.
(d) True. B has 11 columns so its rank cannot be more.
6. Let f be a single-variable, real-valued function such that all its derivatives exist. We say that f changes sign
at some point x0 in the domain if f (x0 + ) · f (x0 − ) < 0 holds for small enough, positive .
• A point x0 in the domain is called a turning point of f , if the first derivative f 0 changes sign at x0 .
• A point x0 in the domain is called flex point of f , if the second derivative f 00 changes sign at x0 .
2
Solution: TFFF. Truth of (a) follows from the definition. Consider the function x 7→ x3 ; at the only critical
point x = 0 the first derivative does not change sign. The same function works as a counter example for (d);
x = 0 is a flex as well as critical point. For (c) consider x 7→ x4 , the second derivative vanishes at 0 but does
not change its sign.
7. Solitaire Tic-Tac-Toe is a new game on the market. Instead of adding X’s and O’s to an empty 3 × 3 grid,
you start with a 3 × 3 grid in which every position already has an X or an O. In each move, you select a row,
column or diagonal and reverse all the entries along the chosen line: all X’s become O’s and all O’s become
X’s.
For instance, here is a sequence of possible moves.
Given an arrangement S, we want to explore all arrangements of the grid that we can generate starting with
S. What is the smallest number m such that each such arrangement can be reached using at most m moves,
starting with S?
(a) 8
(b) 16
(c) 64
(d) 256
Solution: (a) 8.
There are 3 rows, 3 columns and 2 diagonals. At most you can select each of the 8 possible moves once. A
second selection undoes the effect of the move.
8. A bug starts walking from the origin of a two dimensional plane. It walks 1 step up, 1/2 step to the left
then 1/4 step down, then 1/8 step to the right, then 1/16 step up and so on, forever. In (x, y)-coordinates,
its final position is given by
(a) (− 32 , 45 )
(b) (− 25 , 43 )
(c) (− 52 , 45 )
(d) (− 23 , 43 )
−1/2 2
−1/2 + 1/8 − 1/32 + . . . = =−
1 + 1/4 5
y-coordinate is
1 4
1 − 1/4 + 1/16 − . . . = =
1 + 1/4 5
9. Let A, B, C be events such that P (A) = P (B) = P (C) = 0.5, P (A ∩ B) = 0.3, P (A ∩ C) = 0. Which of the
following is/are true?
(a) P (A ∪ B) = 0.75
(b) P (A ∪ C) = 1
(c) P (B ∩ C) = 0.2
3
(d) P (B ∪ C) = 0.9
Solution: (b), (c) FTTF . (a) is false since P (A ∪ B) = P (A) + P (B) − P (A ∩ B) = 0.7. (b) is true
since P (A ∪ C) = P (A) + P (C) − P (A ∩ C) = 1. (c) is true since, in view of (b) C = Ac and thus
P (B) = P (B ∩ A) + P (B ∩ C). (d) Using (c) it follows that P (B ∪ C) = 0.8.
10. The mean and variance of a data set of size n ≥ 100 are 1.1 and 4.3 respectively. It was then discovered that
one data point was wrongly recorded as -0.9 and should be ignored. Then we can conclude that the mean µ
and variance σ 2 of the n − 1 data points satisfy
Solution: FTTF Since the dropped data point is below the mean, the new mean will only go up. Since the
gap between the mean and the dropped data (2) is less that the standard deviation (sqrare root of 4.3), the
variance will increase also.
11. An n × n matrix A = (aij ) is said to be antisymmetric if aij = −aji for all 1 ≤ i, j ≤ n. Which of the
following is/are true?
(a) If A is antisymmetric then all its principal diagonal entries are zero.
(b) If A, B are antisymmetric matrices then the product AB need not be antisymmetric.
(c) If A is antisymmetric then A2 is symmetric.
(d) Every nonzero 3 × 3 antisymmetric matrix is invertible.
Solution: TTTF. (a) follows from the definition. For (b) even a 2 × 2 example works. (c) also follows from
the definition. For (d) use the fact det(AT ) = det(A). Since AT = −A for the 3 × 3 case we have det(A) is
−det(A).
12. Consider the set S = {0, 1, 2, . . . , n − 1} ; n ≥ 2. Let x be an element sampled uniformly at random from S.
Let y denote (x + 2n ) mod n. Which of the following statements is/are true?
√ √
(a) Pr y = b n − 1c = b n−1c
n
(b) Pr[x = a, y = b] = Pr[x = a] · Pr[y = b] for all a, b ∈ S
(c) y is always an element of S
(d) Pr [y = blog2 (n − 1)c] = 1/n
Solution: FFTT.
(a) and (d): Since x is a uniformly random element in S, the value y = (x + t) mod n is also a uniformly
random element in S, for any deterministically chosen t. Hence, the probability that y equals a specific
element in S is 1/n.
(c): Clearly, y belongs to S by definition.
(b): The random variable y depends on x. Hence, (b) is false.
13. A perfect shuffle of a deck of cards divides the deck into two equal parts and then interleaves the cards from
each half, starting with the first card of the first half.
For instance, if we shuffle a deck of cards containing 10 cards arranged [1, 2, 3, 4, 5, 6, 7, 8, 9, 10], we first
create two equal decks with cards [1, 2, 3, 4, 5] and [6, 7, 8, 9, 10] and then interleave them to get a new deck
[1, 6, 2, 7, 3, 8, 4, 9, 5, 10].
We start with the deck [8, 1, 4, 5, 3, 6, 2, 7] and keep shuffling. Which card(s) will never appear next to 5?
4
(a) 1
(b) 2
(c) 7
(d) 8
Solution: (d) 8
The shuffles cycle through three decks, [8, 1, 4, 5, 3, 6, 2, 7], [8, 3, 1, 6, 4, 2, 5, 7] and [8, 4, 3, 2, 1, 5, 6, 7].
14. Consider the following pseudocodes of two functions, where u % 2 denotes the remainder when u is divided
by 2. The function abs(v) returns the absolute value of an integer v.
function foo1 ( u ):
if u % 2 == 0 AND abs ( u ) > 0:
u = u + foo2 (u -1)
return u
function foo2 ( v ):
if v % 2 == 1 AND abs ( v ) > 1:
v = v + foo1 (v -1)
return v
Solution: FTTT
(a) is false since for an odd integer it returns the odd integer. (b) is true. Starting with an odd integer,
it adds that number to the result of foo1 applied to an even integer. foo2(1)=1. foo1(2)=3. Now we can
proceed by induction to show that foor2 on an odd integer computes u(u+1)/2 and foo1 on an even integer
computes u(u+1)/2.
(a) Let f : X → Y , g : Y → Z be functions. such that the composite function g ◦ f : X → Z is onto. Then
both g, f have to be onto.
(b) Assume the cardinality of X, |X|, is less than |Y | and assume |X| ≤ |Z|. There exists a one-one function
f : X → Y and g : Y → Z which is not one-one such that g ◦ f : X → Z is one-one.
5
(c) Let idX be the identity function, idX : X → X, such that idX (x) = x for all x ∈ X. Let f : X → Y be
a function. There exists a function g : Y → X such that g ◦ f = idX .
(d) Denote by idY the identity function on Y , idY (y) = y for all y ∈ Y . Let f : X → Y be a function.
There exists g : Y → X such that f ◦ g = idY if and only if f is onto.
Solution: FTFT. (a) is false. g has to be onto f need not be. b is true. Y has more cardinality than X. g
can be chosen so that it maps the image of f one-one. What it does to elements outside the image we do
not care. c is false. This is true only when f is one-one since we want identity on X. d. Since we want every
element in Y to be covered, f better be onto. In that case we can find such a g.
17. Consider the following real valued functions defined on appropriate domains:
x
f (x) = , g(x) = x ln(x).
x + sin x
Which of the following is/are true?
Solution: TFTF. For (a) use L’Hopital to get the answer. Again using L’Hopital we see that answer for (b)
is 0. For part (c) L’Hopital is useless, instead sandwich theorem gives the answer 1. Since g is an increasing
function (d) is clearly false.
18. Consider the pseudocode below. Here n % 6 denotes the remainder when n is divided by 6. The notation n
// 2 stands for integer division by 2. For example, 15 // 2 = 7, 36 // 2 = 18, 49 // 2 = 24, . . .
function sixer ( n ):
count = 0
while n > 0:
if n % 6 == 0:
n = n - 1
else :
n = n //2
count = count + 1
return count
Which of the following is true when sixer(n) is invoked with sufficiently large n, say n ≥ 106 ?
Solution (c). The key observation is that whenever the code executes the “if” block, in the immediately
following iteration, it executes the “else” block. Clearly, the “else” block can be executed at most dlog2 ne
many times on input n. The statement follows.
19. In a football league, a collection of teams play against each other a number of times. A team gets 3 points
for each match that it wins, 1 point for each match that it draws and 0 points for each match that it loses.
The following table gives the point standings after four teams have played a total of 7 matches. At this
stage, each team has played every other team at least once.
6
Team Matches Points
Kolkata 4 8
Delhi 4 4
Chennai 3 4
Mumbai 3 1
(a) 3
(b) 4
(c) 5
(d) 6
Solution: (b) 4
To reach 8 points, Kolkata must have won 2 matches and drawn 2 matches. With only 1 point from 3
matches, Mumbai has drawn 1 match. Delhi and Chennai with 4 points have drawn at least 1 match each.
Across all teams, the number of drawn matches must be even, so either Chennai or Delhi must have drawn
2 matches. But Chennai cannot have drawn 2 (or 3) matches out of 3 and ended up with 4 points. So Delhi
has drawn at least 2 matches. The only way it can then end up with 4 points is to draw all 4 of its matches.
So Chennai has drawn only 1 match, and Delhi has drawn 4, making 4 draws overall.
20. A new game show on TV has 100 boxes numbered 1, 2, . . . , 100, each containing a mystery prize. The
prizes are of different types, a, b, c, . . . , in decreasing order of value, and are distributed randomly among
the boxes. The most expensive item is of type a, a diamond ring, and there is exactly 1 of these. You are
told that the number of items at least doubles as you move to the next category — there are at least twice
as many items of type b as of type a, at least twice as many items of type c as of type b and so on.
You ask for the type of item in box 45. Instead of being given a direct answer, you are told that there are
31 items of the same type as box 45 in boxes 1 to 44 and 43 items of the same type as box 45 in boxes 46
to 100.
Which of the following statements can be true?
7
Part (B) - Short-answer questions
For questions in part (B), you have to write your answer with a short explanation in the space provided for the
question in your answer sheet. If you need more space, you may continue on the pages provided for rough work.
Any such overflows must be clearly labeled.
1. There are 5 friends A, B, C, D, E. Because of a heated argument not all of them are on speaking terms
anymore. The array below describes who is talking to whom. A value of 1 indicates that the pair is on
speaking terms, while a 0 indicates that they are not.
A B C D E
A - 1 1 1 1
B 1 - 1 0 1
C 1 1 - 1 0
D 1 0 1 - 1
E 1 1 0 1 1
A gossip route is an ordered sequence of all the five friends such that every person hears the gossip from
exactly one friend (with whom they are on speaking terms) and shares it with exactly one other friend (with
whom they are on speaking terms). The friend who starts the gossip doesn’t hear it from anyone else and
the fifth friend doesn’t pass it on to anybody.
Answer the following questions:
(a) Suppose A starts spreading gossip along a gossip route and E hears it the last. Who is the third person
to hear it?
(b) List all the gossip routes from B to E.
(c) There is another dispute between the friends. As a result, A is now not speaking with B and D. List
all the gossip routes starting from A.
Solution: The given matrix is the adjacency matrix of a graph on 5 vertices. A gossip route is a Hamiltonian
path. It is easy to answer once the graph is drawn.
(a) There are only 2 Hamiltonian paths - ABCDE and ADCBE. In both the cases C is the third person
on the route. Either B or D is the third person to hear it.
(b) The routes are BCADE, BACDE, BCDAE.
(c) ACDEB, ACBED and AEBCD, AEDCB.
2. Two friends A and B are playing a coin flipping game with a fair coin, based on the following rules:
Suppose A is the first player to flip the coin. What is the probability that A will win the game.
8
Solution: Answer 23 . Probability that A will on their first flip is 1/2. If not, then B has to flip and get tails
so A can flip a second time. Probability that A wins on their second flip is (1/2)3 . In general the probability
that A wins on their nth flip is (1/2)2n−1 . So the probablility that A wins is
X 1
P (A wins) = ( )2n−1
2
n≥0
1X 1 n
= ( )
2 4
n≥0
1 1
= × 1
2 1− 4
2
= .
3
3. Consider the following real valued function defined on the entire set of real numbers:
1
f (x) = .
1 + e−x
Show that f 0 (x) = f (x)(1 − f (x)).
Solution:
9
1
f (−5) + f (6) = √
3
1
f (−4) + f (5) = √
3
1
f (−3) + f (4) = √
3
1
f (−2) + f (3) = √
3
1
f (−1) + f (2) = √
3
1
f (0) + f (1) = √
3
−−−−−−−−− − −−−−−−−−−−−−−−−−−−
h i 6
f (−5) + f (−4)+ · · · +f (5) + f (6) = √
3
Solution: The determinant is 1. Easy way to see that is to perform row operations to get an upper triangular
matrix with 1’s on the diagonal.
Solution:
10
!
1
L = lim x − x cos √
x→∞ x
!
1
= lim x(1 − cos √ )
x→∞ x
(1 − cos √1x )
!
= lim 1 Apply L’Hopital’s Rules
x→∞
x
sin ( √1x )(− 2x13/2 )
!
= lim
x→∞ − x12
√
sin (1/ x) !
1
− 3/2
2x
= lim
x→∞ − x12
!
1 1 1
= lim x 2 sin ( √ )
x→∞ 2 x
1 1
1
= lim x 2 sin √
2 x→∞ x
1 sin √1x
= lim 1 Apply L’Hopital’s Rules
2 x→∞ x2
cos √1 − 1
1 x 2x3/2
= lim 1
2 x→∞ − 2x3/2
1 1 1
= lim cos √ =
2 x→∞ x 2
7. Let N = 2150 . How many bits are required to write N in binary (base 2)? How many digits are required to
write N in decimal (base 10)? You may assume that log10 2 = 0.30103.
Solution: Bits: 151. In decimal, we want k such that
10k−1 ≤ 2150 < 10k
Solving we get k − 1 ≤ 150 ∗ 0.30103 < k. That is k − 1 ≤ 45.15 < k. So we need 46 digits.
8. A domino is a sheet of paper with one number from {0, 1, 2, 3, 4, 5, 6, 7, 8, 9} printed on each half. For example,
a 4−4 domino has 4 printed on both halves. A 0−4 domino has 0 printed on one half and 4 on the other
half. The order is not important, so a 0−4 domino is the same as a 4−0 domino.
A complete set of dominos is a set of dominos containing exactly one copy of each different domino.
Solution: We have 10 dominos of the kind a−a with the same number on each half. And 10
2 = 45 dominos
with different numbers on the two halves. So a complete set has 10 + 45 = 55 dominos.
For part (b), if one of the selected dominos is 0−9, the other can be any other domino, so we have 54 choices
for the second in this case. Otherwise one domino has a 0 and the other has a 9. The domino with a 0 can
have any of 0, 1, 2, 3, 4, 5, 6, 7, 8 along with it, so 9 choices. If the second has a 9 the other number on it is
one of 1, 2, 3, 4, 5, 6, 7, 8, 9, again 9 choices. So a total of 81 choices for the two, in all. Adding the 54 we have
81 + 54 = 135.
11
9. There are three classrooms, C1 , C2 , and C3 . In C1 there are 5 boys and 5 girls. C2 has 3 boys and 5 girls.
C3 has 5 boys and 3 girls. We select a classroom and then a student in the classroom. The probability of
3 3 4
selecting classrooms C1 , C2 , and C3 are 10 , 10 , and 10 , respectively. Once a room is selected, a student is
picked uniformly at random from the class.
(a) What is the probability that the selected classroom is C3 and the chosen student is a girl?
(b) What is the probability that the selected classroom is C3 given that the chosen student is a girl?
Solution:
Given information
3 4 3
P (C3 and girl) = P (C3 ∩ girl) = P (girl|C3 )P (C3 ) = × =
8 10 20
10. How many integers in the set {1, 2, . . . , 1000} are relatively prime to 1000? Recall that two integers are
relatively prime if the only common factor they have is 1.
Solution: 1000 = 23 ∗ 53 , so we need to remove integers which have 2 or 5 as factors. The number of
integers with 2 as a factor are 500, those with 5 as a factor are 200. However their intersection contains
numbers which are divisible by 10, and that is 100 numbers in all. So the number to be weeded out is
500 + 200 − 100 = 600. Remove these and we are left with 400.
11. Is the following inequality true, given that n is a positive integer?
Z n+1
ln x dx ≤ ln n!
1
12
12. Football teams T1 and T2 play two games against each other in the Premier League. It is assumed that the
outcomes of the two games are independent of each other. The probabilities of T1 winning, drawing and
losing against T2 are 12 , 61 and 13 respectively. Each team gets 3 points for a win, 1 point for a draw and 0
points for a loss in a game. Let X and Y denote the total points scored in these two games by team T1 and
T2 , respectively.
(a) Find P (X = Y ).
(b) Find E(X).
Solution: There are 9 possible outcomes. Write down all 9 possible outcomes for T1 and corresponding X
and Y .
1st Match 2nd Match X Y
w w 6 0
w d 4 1
w l 3 3
d w 4 1
d d 2 2
d l 1 4
l w 3 3
l d 1 4
l l 0 6
P (X = Y ) = P (wl)+P (dd)+p(lw) = P (w)P (l)+P (d)P (d)+P (l)P (w) = 1/2∗1/3+1/6∗1/6+1/3∗1/2 = 13/36
13. Let A, B and C denote arrays of real numbers, where B has n-1 entries and A, C have n entries each. Consider
the following algorithm involving the three given arrays.
for k from 2 to n :
t = B [k -1]
B [k -1] = t / A [k -1]
A [ k ] = A [ k ] - t * B [k -1]
end for
for k from 2 to n :
C [ k ] = C [ k ] - B [k -1] * B [k -1]
end for
13
C [ n ] = C [ n ]/ A [ n ]
for k from n -1 to 1 with steps of -1:
C [ k ] = ( b [ k ]/ A [ k ]) - B [ k ] * b [ k +1]
end for
An arithmetic operation involves addition, subtraction, multiplication or division of real numbers. How
many arithmetic operations, in total, are performed in the algorithm above?
Note: Integer subtraction in array indices, like B[k-1], is not to be counted as an arithmetic operation.
Solution: Answer: 8n − 7 or 8(n − 1) + 1. During each pass of the first for loop one division, one subtraction
and one multiplication is performed. So there are 3(n − 1) arithmetic operations. There are 2(n − 1)
operations in the second for loop and 3(n − 1) operations in the last for loop. The total is 8(n − 1) + 1 or
8n − 7.
14. In the following pseudocode, A denotes an array and len(A) denotes the number of elements in that array.
The array is indexed from 1 to len(A). Write down the array A after each iteration of the for loop when the
input array is <20, 3, 9, 12, 70, 6>.
function weirdify ( A ):
for i from 1 to len ( A ):
if i % 2 == 0:
A [ i ] = A [ i /2]* A [ i ]
else if i * i > len ( A ):
A [ i ] = A [i -2] + 4
else :
A[i] = A[i] - 1
Solution: The purpose of the question is simply to test whether they can read and understand a pseudocode.
Iteration 1: <19, 3, 9, 12, 70, 6>
Iteration 2: <19, 57, 9, 12, 70, 6>
Iteration 3: <19, 57, 23, 12, 70, 6>
Iteration 4: <19, 57, 23, 684, 70, 6>
Iteration 5: <19, 57, 23, 684, 27, 6>
Iteration 6: <19, 57, 23, 684, 27, 138>
15. Consider a city with n East-West Streets (EWS) and n North-South Avenues (NSA). The EWS are the line
segments {y = j | 1 ≤ x ≤ n} for all j ∈ {1, 2, . . . , n} and the NSA are the line segments {x = i | 1 ≤ y ≤ n}
for all i ∈ {1, 2, . . . , n}. A junction is a pair (i, j) where avenue i intersects street j. How many junctions
are there in the city?
For increased safety, the city council decides to place cameras at various junctions in the city. The cameras
being super-powerful, can observe the entire street and avenue corresponding to the junction that they are
placed at. For instance, a camera placed at the junction (i, j) can observe both avenue i and street j. Write
down an expression for the minimum number of cameras needed to observe every street and avenue in the
city.
Justify your answers.
Solution: The number of junctions is n2 since each of the n streets intersect with each of the n avenues at
different points.
At least n cameras are needed. A camera can cover a street and an avenue. If fewer than n cameras are
placed, there is at least one street and at least one avenue that is not covered.
14
16. Find the largest value of xy subject to x2 + y 2 = 2.
√ √
Solution: Let (x, y) = ( 2 cos θ, 2 sin θ). We are asking for the maximum of sin(2θ). It is maximized when
θ is π/4 and the answer is 1. Can be done by inspection too. It is zero on positive x axis and positive y
axis. Since it is nonzero along the arc, a maximum is attained at exactly one position, must be the middle
by symmetry.
17. Each lawyer on a certain remote island is either honest or dishonest (but not both).
• Honest lawyers always speak the truth.
• Dishonest lawyers always lie.
Is it possible for a lawyer on this island to claim that he/ she is dishonest? Explain.
A judge asks lawyer A, “are you honest”? Before A could answer, lawyer B says “A will say yes.” “But
then, he’ll be lying”. Which lawyer is honest and which one is dishonest? Explain.
Solution: It is not possible for a lawyer to claim that they are dishonest. Since, honest lawyers will not lie
and dishonest lawyers will not truthfully admit that they are dishonest.
Suppose A is honest. Then he says “Yes”, which is the truth. This makes B’s first statement True, and B’s
second statement False. So B both lied and spoke the truth, a contradiction.
Now suppose A is dishonest. Then he says “Yes” which is a falsehood. This makes both of B’s statements
True, so there is no contradiction in asserting that B is honest. Thus: A is dishonest, B is honest.
18. A new restaurant chain Burger Paradise has recently opened in Chennai. Burger Paradise offers a variety
of burgers, including vegetarian options, as well as sides and drinks. According to the restaurant’s data,
20% of customers order vegetarian burgers. The restaurant’s data also indicates that customers who order
a burger are twice as likely to order a side of fries than a side of salad.
(a) If the restaurant serves 200 customers daily, what is the expected number of vegetarian burgers they
will sell over a week?
(b) If 30% of the customers order a burger and 60% of those who order a burger order a side of fries, what
is the probability that a customer orders a burger along with a side of fries?
Therefore, the probability that a customer who orders a burger will also order a side of fries is 0.18 or 18%.
15
19. Burger Paradise plans to expand to other cities and is considering opening a new branch in Coimbatore. They
have identified three potential locations, A, B and C, and are evaluating the profitability of each location.
Based on their research, they estimate that the fixed cost for opening a new location will be |50, 00, 000,
|70, 00, 000 and |65, 00, 000 at A, B and C, respectively. They also estimate the variable cost per customer
to be |85 and the average revenue per customer to be |150 at all three locations. They expect to serve
100, 000, 150, 000 and 130, 000 customers in the first year at locations A, B and C, respectively
Which location in Coimbatore is expected to be the most profitable in the first year of operation, and what
is the expected profit at this location?
Solution:
To determine the most profitable location and the expected profit for the first year of operation, we need to
calculate the total revenue, total variable cost, and total contribution margin for each location.
Let’s denote the three potential locations as A, B, and C, with fixed costs of |50,00,000, |70,00,000, and
|65,00,000, respectively. The variable cost per customer served is |85, and the average revenue per customer
is |150. The expected number of customers served in the first year is 100,000 for location A, 150,000 for
location B, and 130,000 for location C.
The total revenue for each location is:
Location A: 100, 000 × |150 = |1, 50, 00, 000
Location B: 150, 000 × |150 = |2, 25, 00, 000
Location C: 130, 000 × |150 = |1, 95, 00, 000
The total variable cost for each location is:
Location A: 100, 000 × |85 = |85, 00, 000
Location B: 150, 000 × |85 = |1, 27, 50, 000
Location C: 130, 000 × |85 = |1, 10, 50, 000
The contribution margin for each location is:
Location A: |1, 50, 00, 000 − |85, 00, 000 = |65, 00, 000
Location B: |2, 25, 00, 000 − |1, 27, 50, 000 = |97, 50, 00
Location C: |1, 95, 00, 000 − |1, 10, 50, 000 = |84, 50, 000
The expected profit for each location is:
Location A: |65, 00, 000 − |50, 00, 000 = |15, 00, 000
Location B: |97, 50, 000 − |70, 00, 000 = |27, 50, 000
Location C: |84, 50, 000 − |65, 00, 000 = |19, 50, 000
Therefore, location B is expected to be the most profitable with an expected profit of |27,50,000 in the first
year of operation.
20. Towns A, B and C are connected to each other by several roads, with at least one road connecting each pair.
In going from one town to another, one can take the road that connects them directly or could travel via
the third town. It is given that, in total, there are 33 roads from A to B, including those via C. Similarly,
there are 23 roads from B to C, including those via A. How many routes are there from A to C, including
those via B?
Solution: Let x be the number of direct roads from A to B (not passing through C). Let y be the number
of direct roads from B to C. Let z be the number of direct roads from A to C. The given information is:
x + yz = 33
y + xz = 23
16
Adding and subtracting gives us
(y − x)(z − 1) = 10
(y + x)(z + 1) = 56
Since (z − 1)|10 and (z + 1)|56 we have z = 3 or 6. Substituting the values in the first set of equations rules
out z = 3. So z = 6 implies x = 3 and y = 5. The final answer is z + xy = 21.
17
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination 2024
Solutions
A = 1234679580, B = 1234789560.
Solution: (a), (c). We need to consider the divisibility by 4, 6, 8, 9, 10. The number A is divisible by
2, 3, 4, 5, 6, 9 and B is divisible by 2, 3, 4, 5, 6, 8, 9.
(a) Let f (x) = x3 + x − 1 for x ∈ R. Then the equation f (x) = 0 has at least one root in [−1, 0).
(b) Let f (x) = x3 + x − 1 for x ∈ R. Then the equation f (x) = 0 has at least one root in [0, 1).
(c) Let f (x) = x3 + x + 1 for x ∈ R. Then the equation f (x) = 0 has at least one root in [0, 1).
(d) Let f (x) = x3 + x + 1 for x ∈ R. Then the equation f (x) = 0 has at least one root in [−1, 0).
Solution: (b), (d). First, (a) is false. Any value in [−1, 0) would result a negative value of f (x). Hence
there is no root in [−1, 0). Second, (b) is true. f (0) = −1 and f (1) = 1. Third, (c) is false as f (x) > 0
for all x ∈ [0, 1). Finally, (d) is true. f (−1) = −1 and f (0) = 1.
3. 26 children participated in a chess tournament. A child got two points for winning, zero for losing and
one point for a draw. Each child played against every other child. After the tournament was over no
child had an odd score. There were no draws in the entire tournament and no two players had the
same score. For convenience assume that the children are named A, B, C, . . . , Z, by the 26 letters of the
English alphabet in increasing order of scores, so A has lowest score, Z has highest score. Thus we have
A < B < C < · · · < X < Y < Z. Pick all statements which are true.
(a) K lost to Q
(b) K lost to B
(c) M lost to N
(d) If L lost to M then N lost to M.
Solution: (a), (c). There are 26 children and no odd score. So the possible scores are 0, 2, 4, 6, ...,
50. Since no two had the same score, and there are exactly 26 even numbers here, all these numbers are
attained. So Z won all games, Y all except against Z, and so on. So N defeated M and Q defeated K.
Statement d is false because the premise is true but the conclusion is false.
4. 14 teams participate in a volleyball tournament. Each team plays the other exactly once. There are no
draws. Assume the teams are labeled by j, 1 ≤ j ≤ 14. Let xj denote the number of games team j wins
and yj the number of games that team j lost. Pick the correct alternative(s):
x2j = yj2 .
P P
(a) j j
x2j > yj2 .
P P
(b) j j
P P
(c) j xj = j yj .
1
P P
(d) j |xj | = j |yj |.
14
P P
Solution: (a),(c), (d). The logic works for any n. Note that xjP= yj = 2 since every game is
won by somebody and lost by somebody. Also xj + yj = 13. Now j x2j = j (13 − yj )2 . The R.H.S.
P
here works out to 132 ∗ 14 − 2 ∗ 13 ∗ j yj + j yj2 . The first two terms cancel out since j yj = 14∗13
P P P
2 .
(a) If x2 = y 2 then x = y.
(b) If x3 = y 3 then x = y.
(c) If x < y then x2 < y 2 .
(d) If x < y then x3 < y 3 .
x3 − y 3 = (x − y)(x2 + xy + y 2 ) < 0.
where AT is the transpose of the matrix A. Which of the following statements are correct?
(a) If equation (1) admits a solution for all b, then A−1 exists.
(b) If equation (1) admits a solution for all b, then equation (2) also admits a solution for all b.
(c) If equation (1) admits a solution for some b, then A−1 exists.
(d) If equation (1) admits a solution for some b, then equation (2) also admits a solution for that b.
Solution: (a), (b). Easy to see that (a) and (b) are correct - uses the fact that if A admits a inverse,
then so does AT .
Solution: (a), (b), (c). (a) is true : Using Taylor’s theorem for f (x) = ex with Lagrange’s form of
2
remainder : f (x) = f (0) + xf ′ (0) + x2 f ′′ (θ) for some θ between 0 and x. Here f ′ (0) = 1, f ′′ (0) = 1 and
f ′′ (θ) > 0 for all θ. (b) is true for n = 1 and n = 2 and for every n > 2, the L.H.S. at (n − 1) gets
multiplied by 2 and R.H.S. at (n − 1) by n. Easy to see that (c) is true while (d) is false for x negative.
2
(b) If A, B are invertible, then inverse of AB is A−1 B −1 .
(c) (A + B)T = AT + B T
(d) Ax = Bx for some n × 1 vector x implies that Ay = By for all n × 1 vectors y.
9. Let x be a variable that takes real values, and let f (x), g(x), h(x) be three polynomials with real-valued
coefficients. Further, let f (x) be a polynomial of degree 1, g(x) a polynomial of degree 2, and h(x) a
polynomial of degree 3. Which of the following statements is/are always true for any three polynomials
of these types?
(a) The graphs of f (x) and g(x) intersect at one or more points.
(b) The graphs of f (x) and h(x) intersect at one or more points.
(c) The graphs of g(x) and h(x) intersect at one or more points.
• (a) is false. Consider f (x) = x, g(x) = x2 + 2. These never intersect because x2 − x + 2 = 0 has no
real roots.
• (b) is true. Let f (x) = ax + b, h(x) = cx3 + dx2 + ex + f . The curves of f (x) and h(x) intersect at
all those values of x which are roots of the cubic polynomial cx3 + dx2 + (e − a)x + (f − b). The cubic
has three—perhaps repeated—solutions, of which at most two can have imaginary parts, since such
roots occur in conjugate pairs. So the cubic has at least one real root, and hence the two graphs
intersect at at least one point.
• (c) is true for similar reasons as to why (b) is true.
10. A spherical ball of ice of radius 20m is dropped in a vat of hot water. The ice melts in such a way that
(i) the shape of the ball remains spherical, and (ii) the radius of the ball decreases at a constant rate of
0.5ms−1 . At what rate does the volume of the ice ball decrease, when the radius of the ball is 15m?
Solution: (c). Let r be the radius of the sphere at any instant. Then its volume at that instant is
V = 34 πr3 . The rate at which this volume changes with respect to time t is dV dV dr 2 dr
dt = dr × dt = 4πr × dt .
dr −1 dV 2
Since dt is given to be 0.5ms , we get that dt = 2πr . When r = 15m, this becomes 450πm s . 3 −1
11. Let x be a real-valued variable. What is the range of the function f (x) = sin2 x − sin x + 2?
(a) [0, 2]
(b) [1, 2]
(c) [1, 4]
(d) [ 74 , 4]
Solution: (d). The given expression can be written, by completing the square, as (sin x − 12 )2 + 47 .
The least value of the squared term is 0, attained when sin x = 12 . Trying out the two extreme values
of sin x we get that the squared term is maximum when sin x = −1, and at such an x we get that
f (x) = (− 32 )2 + 74 = 4.
12. In the following code, A is an array indexed from 0 whose elements are all positive integers, and n is the
number of elements in A. It is given that n is at least 2. The operator * denotes multiplication.
3
function foo (A , n ) {
if A [0] > A [1] {
first = A [0];
second = A [1];
} else {
first = A [1];
second = A [0];
}
If A = [15, 7, 16, 12, 17, 14, 16, 4, 13, 12], what will foo(A, 10) return?
(a) 28
(b) 144
(c) 180
(d) 272
Solution: (d). The function returns the product of the two largest numbers (possibly repeated) in the
array given as its argument. For the given array these numbers are 16, 17, and their product is 272.
13. In the following code, A is an array indexed from 0 whose elements are all positive integers, and n is the
number of elements in A.
function foo (A , n ) {
max = 0;
curr = 0;
(a) 2
(b) 3
(c) 4
4
(d) 5
Solution: (b). The function returns the length of a longest strictly increasing consecutive sub-sequence
of the input array. For the given array there are two such sub-sequences—[1, 3, 5] and [2, 4, 7]—each of
length 3.
14. A prominent newspaper conducted a survey among a carefully chosen sample of 1,00,000 voters under
the age of 25. A randomly chosen subset of 60% of this sample were asked the following question: “Have
you ever voted in a general election?” The remaining 40% were asked the following, different question:
“Is it true that you have never voted in a general election?”
The editor in charge of collating the data from the survey, accidentally deleted some of the contents of the
survey database. The only information that survived this mishap was that a total of 54,000 respondents
replied Yes to the question that they got. Specifically, it is not known how many of these Yes answers
correspond to the first question, and how many to the second.
Assume that the sampling was done properly and that the respondents answered truthfully. What
estimate can we derive from just the total number of Yes answers, about the percentage of voters under
the age of 25 that have voted in some general election?
Solution: (c). Let p be the fraction of voters under the age of 25 that have ever voted in a general
7
election. Then we have: 60000p + 40000(1 − p) = 54000. Solving, we get p = 10 = 70%.
15. Let f, g be two real valued functions defined on the set of real numbers. Which of the following statements
are true?
(a) If f (x) is continuous and g(x) discontinuous then the function f (x)+g(x) is necessarily discontinuous.
(b) If f (x) is continuous and g(x) discontinuous then the function f (x)·g(x) is necessarily discontinuous.
(c) If the functions f (x), g(x) are discontinuous at a point c in the domain the function f (x) + g(x) is
also discontinuous at c.
(d) If the functions f (x), g(x) are discontinuous at a point c in the domain the function f (x) · g(x) is
also discontinuous at c.
Solution: (a). First part is straightforward. For the second part consider the functions 1/x and x.
For the last two parts consider the function f (x) = 1 when x ≥ 0 and f (x) = −1 when x < 0, it is
discontinuous at 0. Let g(x) := −f (x), which is also discontinuous at 0. However, both f + g and the
product f g are continuous everywhere.
16. In the following code, A is an array indexed from 0 whose elements are all positive integers, n is the
number of elements in A, and x is a positive integer. The call abs(z) returns the absolute value of integer
z.
function foo (A ,n , x ) {
max = 0;
return ( max );
}
5
If A = [10, 8, 10, 4, 10, 7, 1, 2, 2, 9], what will foo(A, 10, 5) return?
(a) 2
(b) 4
(c) 6
(d) 9
Solution: (d). The function call returns the maximum absolute difference between two elements of A
if this difference is at least 5, and zero otherwise. Since the maximum absolute difference between two
elements of the given array is 9—due to the elements 10, 1—this call returns 9.
17. One day, Captain Haddock receives a mysterious letter with a confusing paragraph. Captain Haddock and
Tintin are investigating the matter. There are two possible suspects: Professor Calculus and Thomson
& Thompson. Based on their past experience:
• The probability that Professor Calculus sends a letter is 60%, while the probability that Thomson
& Thompson send a letter is 40%.
• When Professor Calculus sends letters, there is an 80% probability that the letter contains a con-
fusing paragraph.
• When Thomson & Thompson send letters, there is a 5% probability that the letter contains a
confusing paragraph.
What is the probability that the letter was sent by Professor Calculus?
(a) 0.96
(b) 0.80
(c) 0.50
(d) 0.48
Solution: (a). Let A be the event that Professor Calculus sent the letter. Let B be the event that the
letter contains a confusing paragraph. We are looking for P (A|B). We have P (A) = 0.6 and P (Ac ) = 0.4
and P (B|A) = 0.8 (probability that the letter contains a confusing paragraph when we know that it was
sent by Professor Calculus). P (B|Ac ) = 0.05 (probability that the letter contains a confusing paragraph
when we know that it was sent by Thompson & Thompson). By the theorem of total probability we find
the probability that the letter contains a confusing paragraph is:
18. Let f be a function on the positive real numbers such that f (xy) = f (x) + f (y). If f (2024) = 2 then
which of the following statement(s) is/ are true?
1
(a) f ( 2024 )=1
1
(b) f ( 2024 ) = −1
1
(c) f ( 2024 ) = −2
1
(d) f ( 2024 )=2
Solution: (c). We have, f (1) = 2f (1), so f (1) = 0. So f (1) = f (2024) + f (1/2024), hence the answer.
6
The following description is for questions 19 and 20.
A perfect shuffle of a deck of cards divides the deck into two equal parts and then interleaves the cards from
each half, starting with the first card of the first half.
For instance, if we shuffle a deck of cards containing 10 cards arranged [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] we first
create two equal decks with cards [1, 2, 3, 4, 5] and [6, 7, 8, 9, 10] and then interleave them to get a new deck
[1, 6, 2, 7, 3, 8, 4, 9, 5, 10].
19. We shuffle the deck [3, 6, 11, 4, 7, 9, 2, 8, 5, 10, 12, 1]. What are the neighbours of 4 after the shuffle?
(a) 1
(b) 5
(c) 10
(d) 12
Solution: (b), (c). Since the shuffled deck is [3, 2, 6, 8, 11, 5, 4, 10, 7, 12, 9, 1].
20. After shuffling once we obtain a deck with cards [15, 6, 4, 1, 13, 9, 8, 7, 12, 11, 5, 10, 3, 14, 2, 16]. What were
the neighbours of 2 before the deck was shuffled?
(a) 3
(b) 6
(c) 7
(d) 14
Solution: (a), (b). Write down the shuffled deck, then the answer is straightforward.
7
Part (B) - Short-answer questions
For questions in part (B), you have to write your answer with a short explanation in the space
provided for the question in your answer sheet. If you need more space, you may continue on the
pages provided for rough work. Any such overflows must be clearly labeled.
1. In the Easy Round, all questions are easy, and each prize is |1000. Guest Chatur knows all the answers.
What is the expected earnings for Chatur in this round? Explain your answer.
Solution: |4500. Explanation: For each 1 ≤ i ≤ 10 the probability that the empty box is labelled i,
is 1/10. The cumulative earnings for each value i of the label of the empty box are: 1 : 0, 2 : 1000,
3 : 2000, 4 : 3000, and so on, up till 10 : 9000. Note that, the expected earning if the round ends after
9
2nd questions is (1000)( 10 )( 19 ), after 3rd question is (2000)( 10
9
)( 89 )( 81 ) etc. So the expected earnings for
Chatur from this round is (1000 + 2000 + · · · + 9000)/10 = |4500.
2. To proceed to the next round, a guest must earn at least |7000 in the Easy Round. What is the
probability that guest Chatur, who knows all the answers of the Easy Round, progresses to the second
round? Explain your answer.
Solution: 3/10. Explanation: For each 1 ≤ i ≤ 10, the probability that the empty box is labelled i,
is 1/10. Chatur fails to move on to the second round exactly when this label takes one of the values
from 1 to 7. The probability of this happening is 7/10, since for i ̸= j the two events “the empty box
is labelled i” and “the empty box is labelled j” are disjoint. So Chatur progresses to the second round
with probability 3/10.
r r
x y 5
+ =
y x 2
x y 9
√ +√ = .
y x 2
Solution: Either x = 1, y = 4, or x = 4, y = 1.
The key is to realize that the first equation is of the form z + (1/z) = c, and hence is a quadratic equation
that can be solved to find the ratio x/y.
q
Set z = xy . Then the first equation becomes z + (1/z) = 5/2. Simplifying and solving the resulting
q
quadratic equation, we get z ∈ {2, 1/2}. Suppose z = 2. Then xy = 2, and so x = 4y. Substituting
q
this in the second equation we get y = 1, and thence x = 4. Suppose z = 1/2. Then xy = 1/2, and so
y = 4x. Substituting this in the second equation we get x = 1, and thence y = 4.
8
Questions 4 and 5 are based on the following description.
The following question appeared in a quiz:
“Write the code for a function SecondBest(A,n) that takes an array A and a positive integer n
as arguments. The elements of A are all integers, and n is the number of elements in A. The call
SecondBest(A,n) should return the second largest element in A. If A has no second largest element,
then the function should return the special value None.”
A student submitted the code below as the answer to this question. In the code the array A is indexed from 0.
function SecondBest (A , n ) {
if n == 1 {
return ( None );
}
first = A [0];
second = A [1];
if first != second {
return ( second );
} else {
return ( None );
}
}
This answer turned out to be wrong; this function gives the correct answer for some valid inputs, and wrong
answers for other valid inputs. Answer the next two questions about this function.
4. What do the following function calls return? Briefly explain your answer.
(a) SecondBest([2,2,3], 3)
(b) SecondBest([3,2,2], 3)
Solution: For both these inputs the function returns the correct answer, namely 2.
5. Give one example of an input array A with exactly 3 elements for which the call SecondBest(A, 3)
returns a wrong answer. What is this wrong answer? What is the correct answer?
Solution: Some examples of such inputs are:
In each case, an explanation would involve a description of how the code sets the values first and
second, and how the comparisons in the final if block using these values, results in a wrong answer.
9
6. Let F be the set of points on the plane with coordinates (x, y) such that ||x| − |y|| + |x| + |y| = 4. What
is the number of points in F with integer coordinates?
Solution: Suppose |x| ≥ |y|, then we have |x|−|y|+|x|+|y| = 4. Or 2|x| = 4, so |x| = 2. So if x = 2, then
y can take values from [−2, 2]. On the other hand if |x| ≤ |y| then we get 2|y| = 4, so |y| = 2 and x takes
the values in the range [−2, 2]. So the points are (2, −2), (2, −1), (2, 0), (2, 1), (2, 2), (−2, −2), (−2, −1),
(−2, 0), (−2, 1), (−2, 2), (1, 2), (0, 2), (1, 2), (−1, −2), (0, −2), (1, −2), a total of 16 points.
7. We select three points at random on the circumference of a circle. What is the probability that ∆ABC
contains the centre O in the interior?
Solution: Assume the circumference is 1 unit. Take the first point. The diameter joining this point and
the centre divides the circumference into two halves. Choose the second point on any of the two halves.
The calculation doesn’t change. Now the third has to be on the other half for the center to be in the
triangle. If the second point is at a distance x from the first, the third has to be choosen in an arc of
length x (out of 1/2) so the probability of success is 2x. Integrating this over 0 to 1/2 we get 2x2 /2 which
is 1/4. Note that with probability 1/2 the second was on either side, so the final probability is 1/4.
Write down an expression for f 10 (x, y), where f 10 denotes the function obtained by composing f with
itself 10 times.
Solution: One may realize that this map is the rotation about the origin by α. So, applying it ten
times we get the rotation by 10α, i.e., in the expression above α is to be replaced by 10α. However, one
need not know this fact; by explicitly composing f with it self and doing the calculations it is clear what
the pattern is. (Note - some may consider 10 compositions as applying the functions 11 times. In that
case the answer is 11α. Since this is not a problem about convention either of the answer is considered
correct. The important thing is to be able to understand the concept).
9. “I’ve defeated more than 10 FIDE masters,” a chess player boasted. “Surely, it must be fewer than 10,”
said the referee. “Well, I suppose it was at least one,” said the Grand Master. If exactly one of them
spoke the truth, how many FIDE masters did the chess player actually defeated?
Solution: The answer is that the player defeated not a single FIDE master. Since exactly one statement
is true, there are 3 choices as follows: If the statement 1 is true then the statement 3 can’t be false, a
contradiction. If the statement 3 is true and the statement 2 is false then the statement 2 can’t be false.
However, if one considers that there is strict inequality in statements 1 and 2 and that the player has
defeated exactly 10 players then both these statements are false and only the Grand Master is speaking
the truth. Finally, if the statement 2 is true then the statement 1 false and the statement 3 will be false if
the player did not defeat any FIDE master. Hence, the player has defeated either 0 or 10 FIDE masters.
10. A supplier of art material has four reams of handmade paper, three boxes of acrylic colors and two
printing blocks. The two artists in the shop want to buy one item each, but insist on having the same
kind of art material. How many items does the supplier have to take out to be sure that the artists’
demand is met?
Solution: The supplier has to take out at least 4 items; in order to have at least two of those of one
type. Note that this is a pigeonhole principal problem, with 9 pigeons and 3 holes. The shopkeeper can,
first, take out 1 item each of the 3 types and then the 4th item of taken out such that the demand is met.
11. In a farmer’s stable three animals, a donkey, a cow and a horse had to share two types of feed bags, one
containing hay and the other containing grain, as follows:
• If the donkey ate grain then the horse ate what the cow ate.
• If the horse ate grain then then donkey ate what the cow did not eat.
• If the cow ate hay, then the donkey ate what the horse ate.
10
Among all the assignments of feedbags that satisfy the above condition which animal always gets to eat
from the same feedbag?
Solution: When all the 3 conditions are satisfied, only the donkey always eats from the feed bag
containing hay. There are 2 feed bags - grains and hay, so we can start with 8 possibilities of assigning
them. If the donkey eats grains then the horse and the cow have to share the same food. However, all
of them can’t eat grains since it contradicts condition 2. The combination grains, hay, hay contradicts
the last condition. Concluding that the donkey can never eat grains. The assignment where the horse
eats grains and the donkey and the cow eat hay contradicts condition 2. Hence, there are exactly 3
possibilities that satisfy the given three conditions and in each, the donkey eats from the hay feed bag.
12. There are 7 elevators in a large shopping mall, each stopping at ground floor and at most six other floors.
If at least 3 elevators stop at each floor and if it is possible to go from any floor to any other floor without
changing elevators, what is the maximum number of floors in the mall?
Solution: There are at most 14 floors = 7 (elevators) × 6 (stops per elevator)/3 (stops per floor). Here
is a sample elevator-floor assignment that serves 14 floors. For each elevator we give 6 floors at which it
should stop.
(a) Elevator 1: floors 1, 2, 3, 4, 5, 6.
(b) Elevator 2: floors 1, 2, 7, 8, 11, 12.
(c) Elevator 3: floors 1, 2, 9, 10, 13, 14.
(d) Elevator 4: floors 3, 4, 7, 8, 13, 14.
(e) Elevator 5: floors 5, 6, 7, 8, 9, 10.
(f) Elevator 6: floors 3, 4, 9, 10, 11, 12.
(g) Elevator 7: floors 5, 6, 11, 12, 13, 14.
For example, if someone wants to go from 6th floor to 10th then they should use Elevator 5. The fourth
floor is served by exactly 3 elevators, namely, 1, 4 and 6.
13. Consider the following expression
√ √
q q
x + 2 x − 1 + x − 2 x − 1.
Find two real numbers a, b such that the above expression is constant for a ≤ x ≤ b.
Solution: One does the following simplification -
q √ q √
f (x) = (x − 1) + 2 x − 1 + 1 + (x − 1) − 2 x − 1 + 1
q√ q√
= ( x − 1 + 1)2 + ( x − 1 − 1)2
√ √
= x − 1 + 1 + | x − 1 − 1|.
√
Hence, the expression is undefined for x < 1 and it is 2 x − 1 for x > 2. However, for 1 ≤ x ≤ 2 the
expression is 2.
14. You are given a strange, analogue wall clock whose hour and minute hands are identical. Both the hands
move continuously and there is no second hand. How many times are there from noon to midnight when
it is not possible to tell what time is it by looking at the clock at that instant? For example, at 06 : 00
pm one can be sure that the upper hand is the minute hand, for otherwise at 12 : 30 pm the top hand
is between 12 and 1. However, a bit after 1 : 15 pm and 3 : 06 pm the clock looks identical and you
wouldn’t be able to tell the exact time.
Solution: The answer is 132. Here is an explanation - when the hour hand has moved x degrees
around the clock from the top, the minute hand has moved y = 12x degrees. If the time is still a valid
configuration when the hands are switched around then x = 12y as well. Hence there 144 configurations
that are indistinguishable, for example, the position at 1 : 51 is identical to that at 10 : 09 if the hands
are identical. Same is true when the time is 4 : 47 or 9 : 24 etc. However, of these 144 configurations
there are exactly 12 configurations in which the hour and the minute hand are in the exact same position.
In such a case it doesn’t matter which hand is which because we can still tell the time. So, there are
exactly 144 − 12 = 132 ambiguous configurations.
11
15. Does there exist a polynomial q(x) with integer coefficients such that q(1) = 2 and q(3) = 5? Given an
example if there is one. Justify, if there is not.
Solution: Such a polynomial can’t exist because
3 = q(3) − q(1)
X
= ai (3i − 1i )
i
The left hand side is odd and the right hand side is even, a contradiction.
16. Find the number of all 4-digit natural numbers formed with exactly two distinct digits.
Solution: The answer is 567. First choose 2 distinct digits can be chosen from 10 available digits in 45
ways. With the selected 2 digits one can form 24 different 4-digit positive integers. However, there are
two integers with all the 4 digits same. Finally, we have to discard those ‘integers’ that start with 0.
Hence the final answer is
4 9
45(2 − 2) − (23 − 1) = 630 − 63 = 567.
1
17. An electronic card shuffling machine always rearranges the cards in the same way relative to the order
in which they are placed in it. One iteration of shuffling means that the cards are placed in the machine
and they are taken out after the rearrangement. Two iterations means that you place the cards in the
machine immediately after the first iteration. The ace through the king of hearts are arranged in order
with the ace on top and the king at the bottom. After 2 iterations the order of the cards, from top to
bottom, is
10, 9, Q, 8, K, 3, 4, A, 5, J, 6, 2, 7.
1 → 8 → 4 → 7 → 13 → 5 → 9 → 2 → 12 → 3 → 6 → 11 → 10 → 1.
We see that there are no smaller cycles in f 2 , which means they can’t be there in f as well. Hence we
have to start with every number and then move to right, 13 places. You will see that the order returns.
In June 2017, a cyberattack named NotPetya spread all over the world. Big companies like Marex, Merck, and
FedEx’s TNT Express lost a lot of money because of this attack.
18. Which company experienced the smallest percentage decrease in total revenue over a one month period
relative to its estimated total revenue over the same period?
Solution: First, intermediate calculations. The average monthly revenue (loss) for each company:
12
• Marex 1000 − 700 = 300 million USD.
• Merc 800 − 480 = 320 million USD.
• TNT 500 − 250 = 250 million USD
The percentage decrease in total revenue relative to the total revenue for each company:
• Marex: 1000
300
× 100 = 30%
• Merc: 800 × 100 = 40%
320
Answer: Marex experienced the smallest percentage decrease in total revenue, with a decrease of 30%.
This calculation reflects that, even though all companies faced significant losses, Marex’s total revenue
impact was relatively smaller in percentage terms compared to the others.
19. Calculate the overall percentage decrease in revenue across all three companies in one month period
following the NotPetya attack.
Solution: First, intermediate calculations. The total monthly revenue before and after the attack for all
companies:
• Before attack: Total = Maersk (1000) + Merck (800) + TNT Express (500) = 2300 million USD
• After attack: Total = Maersk (700) + Merck (480) + TNT Express (250) = 1430 million USD
Total revenue lost = 2300 - 1430 = 870 million USD
870
The overall percentage decrease in revenue = 2300 × 100% ≈ 37.83%
Answer: The overall percentage decrease in revenue across all three companies in the month following
the NotPetya attack is approximately 37.83%.
20. Assuming the monthly revenue of Marex follows a Gaussian distribution with a standard deviation of 75,
(i) what is the probability that Marex’s revenue will be less than $850 million in the pre-attack scenario,
and (ii) what is the probability that Marex’s revenue will be more than $850 million in the post-attack
scenario?
z P (Z ≤ z)
-2 0.0227
-1 0.1586
0 0.5000
1 0.8413
2 0.9772
Solution: The pre-attack scenario. Suppose R is the monthly revenue and R ∼ N (µ = 1000, σ = 75)
R − 1000 850 − 1000
P (R ≤ 850) = P ≤
75 75
= P (Z ≤ −2), where Z ∼ N (0, 1)
= 0.0227
The post-attack scenario. Suppose R is the monthly revenue and R ∼ N (µ = 700, σ = 75)
R − 700 850 − 700
P (R ≥ 850) = P ≥
75 75
= P (Z ≥ 2), where Z ∼ N (0, 1)
= 1 − P (Z ≤ 2)
= 1 − 0.9772
= 0.0227
13
CHENNAI MATHEMATICAL INSTITUTE
[Link]. Data Science Entrance Examination 2025
IMPORTANT INSTRUCTIONS
• Part (A) consists of multiple-choice questions. There may be multiple correct choices. You have to select
all the correct options and no incorrect option to get full marks. There is no partial credit.
• For questions in part (A), you have to provide the answers on the computer. You only have to choose
the appropriate answer(s) from the choices provided. If the answer is parts (a) and (c), choose only (a)
and (c).
• Important Note: Please ignore Page 3 of your answer booklet that says Answers to part A. There is
no need to write your answers there. Only answers entered in the computer will be considered.
• For questions in part (B), you have to write your answer with a short explanation in the space provided
for the question.
• Part(A) will be used for screening. Part (B) will be graded only if you score a certain minimum in
part (A). However your scores in both parts will be used while making the final decision.
• For numerical answers, the following forms are acceptable: fractions, decimals, symbolic e.g.: nr , n Pr ,
n! etc.
• f is said to be surjective (or onto) for every y ∈ B there exists x ∈ A such that f (x) = y;
• f is said to be invertible if there exists a function g from B to A such that f (g(y)) = y for all y ∈ B
and g(f (x)) = x for all x ∈ A.
• For a matrix A, AT denotes the transpose of A. For a square matrix A, |A| denotes the determinant of
A and trace(A) denotes the trace of A — namely the sum of the diagonal elements of A.
• A diagonal matrix is a square matrix D with all off-diagonal entries equal to zero i.e. dij = 0 for all
i ̸= j.
• An upper triangular matrix is a square matrix A for which all entries below the diagonal are zero, i.e.
aij = 0 for i > j.
• A symmetric matrix is a square matrix S for which sij = sji for all i ̸= j.
1
Part (A) - Multiple-choice questions
1. Let X = {1, 2, 3} and Y = {a, b, c, d} be two finite sets. Which of the following statements regarding
functions from X → Y is/are true?
Solution: Options (c), (d). Y has more elements hence we can’t have onto functions from X to Y . The
number of one-to-one functions is the same as choosing 3 distinct elements from Y and then assigning
them to the elements of X in 3! ways.
2. The two arguments to the function foo(A, n) in the code below are: (i) an integer array A indexed from
0, and (ii) the number n of elements in A.
function foo (A , n ) {
count = 0;
for i from 0 to (n -1) {
for j from ( i +1) to (n -1) {
if ( A [ i ] > 2 * A [ j ]) {
count = count + 1;
}
}
}
return ( count );
}
Which of the following statements about the function foo(A, n) are correct?
(a) foo(A, n) counts the number of index pairs (i, j) such that i < j and A[i] > 2 × A[j].
(b) For the input A = [1, -4, 3, -5, -2], n = 5, the function returns 7.
(c) For the input A = [1, 2, 3, 4, 5], n = 5, the function returns 0.
(d) For the input A = [10, 5, 1], n = 3, the function returns 2.
So, 2 pairs.
(a) (−∞, 2)
(b) (3, ∞)
(c) (−∞, 2) ∪ (3, ∞)
(d) (−∞, ∞)
2
Solution: Option (c), (−∞, 2) ∪ (3, ∞).
The argument of a logarithmic function must be positive:
x2 − 5x + 6 > 0 ⇐⇒ (x − 2)(x − 3) > 0
The latter condition holds if and only if exactly one of the following holds:
So the function f (x) is defined exactly when x < 2 or x > 3. This corresponds to the union of intervals
(−∞, 2) ∪ (3, ∞).
a b
4. Let A = be a real matrix which satisfies A−1 = A. Which of the following statements is/are
c d
always true?
(a) a + d = 0
(b) ad − bc = 1
(c) ad − bc ̸= 0
(d) a2 + 2bc + d2 = 2
5. Let Z be the set of all integers. Let A = {n ∈ Z | n2 + 10n + 21 is divisible by 7}. Which of the following
statements is/are true?
(a) A = {n ∈ Z | (n ≡ 0 mod 7)}
(b) A = {n ∈ Z | (n ≡ 0 mod 7) or (n ≡ 4 mod 7)}
(c) A = {n ∈ Z | (n ≡ 1 mod 7) or (n ≡ 5 mod 7)}
(d) A = {n ∈ Z | (n ≡ 2 mod 7) or (n ≡ 6 mod 7)}
Solution: Option (b), A = {n ∈ Z | (n ≡ 0 mod 7) or (n ≡ 4 mod 7)}.
Factoring the expression, we get n2 + 10n + 21 = (n + 3)(n + 7). Since 7 is a prime number, this product
is divisible by 7 exactly when at least one of the following holds:
• n + 3 is divisible by 7. This is equivalent to n ≡ 4 mod 7
• n + 7 is divisible by 7. This is equivalent to n ≡ 0 mod 7
Since the equivalence classes of N modulo 7 are disjoint, (b) is the only correct answer.
6. Let n ≥ 3 be an integer, and let x1 , x2 , . . . , xn be variables which take real values with 0 ≤ xi ≤ 1 for all
1 ≤ i ≤ n. Let
A = x1 + x2 + . . . + xn
B = x1 x2 + x2 x3 + . . . + xn−1 xn + xn x1
3
(a) A ≥ B is always true.
(b) B > A is true for some values of the xi ’s and A > B is true for some values of the xi ’s.
(c) A = B has a finite number of solutions
(d) A = B has an infinite number of solutions.
ai,j = bp(i),p(j) , 1 ≤ i, j ≤ n.
Which of the following statement(s) is/are true for all choices of B and P .
Solution: Options (a), (c). Option (a) is true since the absolute value of the determinant of A is same as
that of B. Option
(c) is true
since
the diagonal elements are preserved. Option (b) is false; for example,
1 2 3 0 0
let ,y and A = . Option (d) is false as the eigenvectors are permuted by the bijection
0 0 0 2 1
p.
8. Let x be a variable that takes real values, and let f (x) = x3 − 3x. Which of the following statements
is/are true?
√
(a) f (x) has a local maximum at x = − 3
(b) f (x) has a local maximum at x = −1
√
(c) f (x) has a local minimum at x = 3
(d) f (x) has a global minimum at x = 1
9. A binary relation R defined on a set S is said to be antisymmetric if for x, y ∈ S, xRy and yRx =⇒
x = y. Let R1 , R2 be two binary relations defined on a set S. The union of R1 , R2 is the binary relation
U defined on S as: For x, y ∈ S, xU y ⇐⇒ xR1 y or xR2 y. The intersection of R1 , R2 is the binary
relation I defined on S as: For x, y ∈ S, xIy ⇐⇒ xR1 y and xR2 y.
Which of the following statements is/are true?
• (a) is false. E.g.: the identity relation is both symmetric and antisymmetric.
• (b) is true. E.g.: the “less than” relation on integers is both transitive and antisymmetric.
4
• (c) is false. E.g.: Consider the following two relations defined on the set S = {1, 2, 3, . . . , 100}:
– xR1 y: x and y are related if (i) x and y are both integral powers of 2, or if (ii) neither x nor y
is an integral power of 2;
– xR2 y if and only if x ≡ y mod 2.
Let U be the union of R1 and R2 . Then: 2U 4 since 2R1 4 and 4U 14 since 4R2 14. But 2 is not
related to 14 by U , since 2 and 14 are not related by either R1 or R2 . Thus U is not transitive, and
hence is not an equivalence relation.
• (d) is true. This follows from a straightforward application of the definitions of set intersection and
an equivalence relation.
10. In how many ways can 10 identical chocolate bars be distributed among 5 children, in such a way that
each child gets at least one chocolate bar?
(a) 50
(b) 126
(c) 252
(d) 3125
(a) ¬P ∨ Q
(b) ¬P ∧ Q
(c) Q =⇒ P
(d) P ∧ ¬Q
Solution: Option (d), P ∧ ¬Q. This can be found, for instance, using truth tables.
√
12. Let f (x) = x. We draw a tangent to the curve y = f (x) at the point on the curve whose x coordinate
is equal to 4. Where does this tangent intersect the X-axis?
(a) x = 4
(b) x = −2
(c) x = −4
(d) x = 2
13. Let n be an integer, n ≥ 4. A is an n × n matrix with real entries. The matrix B is obtained by the
following sequence of operations on A. First, multiply each entry of A by 2. Then add 3 times the second
column to the third column. Finally, swap the first and the fourth columns. If det(A) = 5, which of the
following statements are true?
5
(a) 10 divides det(B)
(b) det(B) = −5
(c) 100 divides det(B)
(d) det(B) = −2n · 5
14. Let x, y, z be positive numbers such that x2 + y 2 = z 2 . Determine the value of the following expression:
logy+z x + logz−y x
.
(logy+z x)(logz−y x)
(a) Undefined.
1
(b) 2
1
(c) 4
(d) 2
Solution: Let logz+y x = u and let logz−y x = v. We wish to compute 1/u + 1/v. Then (y + z)u = x and
(z − y)v = x. So y + z = x1/u and z − y = x1/v . So z 2 − y 2 = x2 = x1/u x1/v = x1/u+1/v . So 1/u + 1/v = 2.
Note: One can choose x, z such that z is odd and x2 = z − 1. For example, x = 3, z = 5 or x = 5, z = 13
etc. In such cases, z − y = 1 and hence logz−y x = log1 x, an undefined quantity. The way out is to
interchange the roles of x and y. Since, the question did not specifically mentions how x, y are chosen
given z, Option (a) Undefined is also a valid answer. Candidates who picked either (a) or (d) or both (a)
and (d) have received full marks for this question. We thank the candidate who pointed out this case.
15. A game being offered in a casino consists of guessing the outcomes of two tosses of a fair coin. The
gambler wins if she/he has correctly guessed at least one of the two tosses. To play a game, the gambler
has to pay a fee of Rs. 80, and the winner gets a reward of Rs. 100 on winning the game (and nothing
otherwise).
Which of the following statements are correct?
(a) In the first 10 minutes on a given day exactly three gamblers play the game, one after the other.
The probability that the casino owner makes a profit in the first 10 minutes equals 1/4.
(b) One gambler plays the game three times. The probability that she wins exactly two of the three
games is 27/64.
(c) Three friends go together and play the game with each playing once. The probability that all three
win equals 27/64.
(d) If 1200 players play the game on a given day, the expected profit of the casino owner for the day
equals Rs. 6000.
Solution: Options (b), (c), (d) are correct. The distribution of the number of wins of the casino owner
in a sequence of 3 games is binomial with p = 1/4. Thus (b) and (c) are correct. The expected profit
from each game is 80-100× 3/4 =5. (a) is false because the owner loses only when all three win, which
is 27/64 thus the probability that owner makes a profit is 37/64.
16. In the following code the operator % denotes the remainder after integer division. That is: for positive
integers a,b the value a % b is the remainder obtained when a is divided by b.
function fizzbuzz ( n ) {
count = 0;
for i from 0 to (n -1) {
if (( i % 3) == 0) and (( i % 5) != 0) {
count = count + 1;
}
}
return ( count );
}
6
What does fizzbuzz(100) return?
(a) 27
(b) 33
(c) 45
(d) 60
for i from 1 to n {
B [ A [ i ]] = B [ A [ i ]] + 1;
}
for i from 1 to n {
if ( found == False ) {
if ( B [ A [ i ]] == 1) {
found = True ;
value = A [ i ];
}
}
}
if ( found == True ) {
return ( value );
} else {
return ( None );
}
}
7
Answer the next three questions about this function.
(a) None
(b) 1
(c) 2
(d) 3
(a) None
(b) 2
(c) 3
(d) 4
(a) 3
(b) 4
(c) 5
(d) 6
8
Part (B) - Short-answer questions
For questions in part (B), you have to write your answer with a short explanation in the space
provided for the question in your answer sheet. If you need more space, you may continue on the
pages provided for rough work. Any such overflows must be clearly labeled.
1. A girl writes five consecutive positive integers on a blackboard. She then erases one of them. The sum
of the remaining four numbers is 2025. What number did she erase?
Solution:
We assume the five consecutive integers are n, n + 1, n + 2, n + 3, n + 4. Their total sum is:
S = 5n + 10
One number is erased and the sum of the remaining four numbers is given as 2025.
Let a be an integer between 0 to 4. Then we have
5n + 10 = 2025 + n + a
4n = 2025 + (a − 10)
The RHS is divisible by 4 only when a = 1. Hence, n = 504 and the erased number is 505. Verification:
the numbers are 504, 505, 506, 507, 508, they add up to 2530 and subtracting 505 gives us 2025.
2. A toy company currently sells 1,000 toys each month at a price of |500 per toy. To increase their sales,
the company is considering to lower the price. Market research shows that for every |10 decrease in the
price, the number of toys sold increases by 100. However, the price cut applies to all the toys sold.
(a) By how much should the company reduce the price, so as to maximize its monthly revenue?
(b) What would be the maximum revenue per month that the company can achieve?
Revenue Function:
Revenue, R(x) = Price per toy × Quantity sold
Take Derivative
d
R′ (x) = (500000 + 4000x − 10x2 ) = 4000 − 20x
dx
Critical Point
9
R′ (x) = 0 ⇒ 4000 − 20x = 0 ⇒ x = 200
Check Maximum
3. 15 balls are placed independently and uniformly at random into 15 bins numbered from 1 to 15. The
1
probability that a ball ends up in a particular bin is 15 .
(a) What is the probability that the first 5 balls go into different bins, conditioned on the event that
first four balls are in different bins?
(b) What are the possible values of the expected number of balls in bin 1 conditioned on the event that
the first 13 balls are in different bins?
Solution: Problem (a) 11/15. Problem (b) Conditioned on X13 , the first bin may have 0 or 1 balls. If
the first bin is empty, then it may have 0, 1 or 2 balls finally. 1 ball is with probability 2 ∗ 1/15 ∗ (14/15).
30
2 balls is with probability 1/225. So the expected value of Y1 is then 225 .
On the other hand, if it already has 1, then the final number can be 1 (w.p 196/225), 2 (w.p 2∗1/15∗14/15
and 3 w.p 1/225. So the expected value is 196/225 + 56/225 + 3/225 which is 255/225.
4. There are 18 chocolates in a bag, of which 7 are green, 6 are blue, and 5 are red. We pick chocolates one
at a time from the bag without replacement.
(a) What is the probability that the first and the third chocolate are green?
(b) What is the probability that after picking twelve chocolates, only chocolates of one colour remain
in the bag?
Solution:
• 16!
5!6!5!
18
divided by 7!6!5! 7∗6
which turns out to be 17∗18 . Another way to see this. If the first three are
7 6 5 7 11 6
green it happens with probability 18 17 16 . If the second is not green the probability is 18 17 16 . These
are disjoint events and the probabilities add to give the same answer.
• We can have all blue or all green left in the bag. If the chocolates remaining are all blue, this can
12!
happen in x := 7!5! ways of picking the first 12. If the remaining chocolates are all green, then in
12!
the first twelve we have picked all red, one green and all blue. Those can be picked in y := 5!6! ways.
x+y
So it is N .
An n × n matrix is said to be elementary if it is the result of a single elementary row operation performed
on the n × n identity matrix.
Which of the following statements is/are true? Justify your answer with a short proof, if the statement
is true, otherwise, provide a counterexample.
10
a Every elementary operation on a n×n matrix A can be performed by multiplying A by an elementary
n × n matrix on the right.
b An elementary row operation on a n × n matrix A results in a matrix with the same determinant
as that of A.
1 0
Solution: Both are false. Example and interchanging the two rows. Scaling changes determinant.
2 0
6. Consider the following polynomial of positive degree n
Show that there is no real number r such that Pn (r) = 0 when n is even.
Solution:
1 − xn+1
(1 − x)Pn (x) = − (n + 1)xn+1
1−x
So
1 − (n + 2)xn+1 + (n + 1)xn+2
Pn (x) =
(1 − x)2
From the given expression of Pn (x) there are no zeros when x > 0. From the above expression, when n
is even, and x < 0, the numerator is positive, so there are no roots.
7. How many positive integers less than 1000 are neither divisible by 3 nor divisible by 5? Explain how
you arrived at your answer.
Solution: The answer is 533.
Let U = {1, 2, . . . , 999}. Let A be the set of all elements of U which are divisible by 3, and let B be
the set of all elements of U which are divisible by 5. Then |A| = ⌊ 999 999
3 ⌋ = 333, |B| = ⌊ 5 ⌋ = 199, and
999
|A ∩ B| = ⌊ 15 ⌋ = 66. The number of elements of U which are divisible by at least one of {3, 5} is
|A ∪ B| = |A| + |B| − |A ∩ B| = 333 + 199 − 66 = 466. The number of elements of U which are divisible
by neither 3 nor 5 is thus |U \ (A ∪ B)| = |U | − |A ∪ B| = 999 − 466 = 533.
8. Three hostel friends Amar, Prem and Raj are suspected of breaking a window. They made the following
statements when questioned by the warden:
You know that exactly one of them lied and the other two told the truth. Then, who broke the window?
Justify.
Solution: Prem broke the window. In addition, he is the one who lied.
Justification: since we are told that exactly one of them lied, so we can assume each of them lied to see
which assumptions lead to contradiction. If Amar lied then Prem is speaking the truth. Which implies
Amar is speaking the truth. A clear contradiction.
Suppose Raj lied. This implies either Raj broke the window or both Amar and Prem are lying, again a
contradiction.
Finally, suppose Prem lied, which means either Amar is telling the truth is false or Raj broke the window
is false. Raj did not break the window doesn’t contradict anything. However, Amar lying certainly
contradicts Prem lying. However, both Amar and Raj are speaking the truth do not contradict anything.
Hence, Prem is lying and his ”Raj broke the window” statement is false, and more importantly, Prem
broke the window.
9. A cloth bag labeled X contains two apples, bag Y contains two oranges and bag Z one apple and one
orange. You pick a bag at random and then remove one fruit from that bag at random. Suppose you
removed an apple. What is the probability that the fruit remaining in the bag is also an apple? Justify.
11
Solution: The answer is 23 .
Justification: Let p(BX ) denote the probability of picking bag X and p(A) be the probability of removing
an apple on the first draw. Hence, we want to calculate
p(A|BX ) · p(BX )
p(BX |A) = .
p(A)
2 1 0 1 1
Note that p(A) = 2 · 3 + 2 · 3 + 2 · 13 . Hence the answer is
1 · 1/3 2
p(BX |A) = = .
1/2 3
“Write the pseudocode for a function Closest(A,n,x) that takes an array A, a positive integer n,
and an integer x as arguments. The elements of A are all integers less than 264 , and n is the number
of elements in A. The call Closest(A,n,x) should return an integer y such that: (i) y ̸= x, (ii) y
is present in A, and (iii) there is no z ̸= x in A where |z − x| < |y − x| holds. If A has no such
element y, then the function should return the special value None.”
A student submitted the code below as the answer to this question. In the code the array A is indexed from 0,
and MAXINT = 264 − 1. The call abs(z) returns the absolute value |z| of integer z.
function Closest (A , n , x ) {
minVal = MAXINT ;
if ( minVal != MAXINT ) {
return ( y );
} else {
return ( None );
}
}
This answer turned out to be wrong; this function gives the correct answer for some valid inputs, and wrong
answers for other valid inputs. Answer the next two questions about this function.
(a) Closest([-10,2,10], 3, 8)
(b) Closest([0,-5,4], 3, 7)
Solution: For both these inputs the function returns the correct answer, namely: 10 for part (a) and 4
for part (b). A complete solution will also explain (e.g., using dry runs) as to why the function returns
these values.
11. Give one example of (i) an input array A with exactly 3 elements and (ii) an integer x for which the call
Closest(A, 3, x) returns a wrong answer. What is this wrong answer? What is the correct answer?
Solution: Some examples of such inputs are:
12
• A = [5, 10, 3], x = 5. The function returns 5. The correct value is 3.
If x is present in A then this pseudocode always outputs x, even if a different number is there in A.
A different kind of input for which this pseudocode gives a wrong answer, is one where the magnitude of
of x is so large that absDiff is larger than MAXINT. For such inputs the function may return None, even
if there is an element of A that satisfies the requirements for a closest element to x.
Using this we get, s1 + s2 = 8 and s4 + s5 = 20. Now we have s3 < s4 =⇒ s3 < s2 + 2, which gives us
5 < s2 < 7.
13. Five executives of a company namely CEO (chief executive officer), CFO (chief financial officer), COO
(chief operating officer), CTO (chief technology officer), CMO (chief marketing officer) are to be seated
around a circular table.
In how many distinct ways can they be seated? (Rotations of the same arrangement are considered the
same).
Solution: There are 2 distinct ways. There are total 5 people so, without restrictions there will be 24
circular permutations. One can begin by considering CEO and CFO has a single unit. Hence, there are
6 ways to arrange (CEO, CFO), COO, CTO, CMO. The unit (CEO, CFO) can be arranged in 2 ways,
hence, in total there are 12 ways in which CEO is seated next to CFO. Now, proceed by adding one
restriction at a time. We get the following 2 valid seating arrangements:
• CEO-CFO-CTO-CMO-COO-CEO
• CEO-COO-CMO-CTO-CFO-CEO
Solution: det(A) = 0; the 3rd column is twice the sum of first and second column.
13
16. Let f : R → R be a function which is twice differentiable everywhere and suppose that f ′ (q) = 0 for
every rational number q. Find the value of f (π 2 ) − f (π).
Solution: 0. Since f ′ exists everywhere and is continuous, its value can’t be nonzero on irrationals. As
the derivative is identically zero the function f is constant.
Read the following description carefully and answer the questions that follow. Use all the information
provided. Clearly show all your calculations.
Description:
NorthCool Beverages Pvt. Ltd. is a leading beverage company that operates across six northern
states of India. During the past summer the company launched an aggressive marketing campaign to
promote its range of flavoured drinks. The charts below summarise the sales data collected during this
campaign.
Uttar Pradesh
Haryana
Punjab
States
Himachal Pradesh
Delhi
Uttarakhand
0 5 10 15 20 25 30
Sales
18. What is the revenue from the sales of Mango flavour drinks.
Solution: Let total revenue be R. Given:
14
19. NorthCool Beverages plans to launch a new variant, “Lemon Max”, in the two states with the highest
sales of the lemon flavour. The company expects Lemon Max to generate additional revenue equal to
20% of the current lemon flavour sales in those two states. What would be the percentage revenue share
of lemon flavour drinks if their expectations are met?
Solutions:
Top 2 states by lemon sales:
Lemon Max will generate 20% additional revenue over this; which is 11 lakhs. So, if the expectations are
met then the total revenue generated by lemon flavoured drinks is 131 lakhs. The total expected revenue
is 439.57 lakhs. Hence, the increased share of lemon flavoured drink is approximately 30% (29.8% to be
precise).
20. On average, for every |1 lakh in total revenue from the lemon-flavoured drink, 10,000 litres of lemon-
flavoured drink are sold across the six states. Estimate the total volume (in litres) of lemon-flavoured
drink sold by NorthCool Beverages across all six states.
solutions: Given:
15