Recent questions tagged cmi2018

4 4 votes
4 4 answers
1.9k
1.9k views
Which of the words below matches the regular expression $a(a+b)^{\ast}b+b(a+b)^{\ast}a$?$aba$$bab$$abba$$aabb$
4 4 votes
3 3 answers
1.3k
1.3k views
Akash, Bharani, Chetan and Deepa are invited to a party. If Bharani and Chetan attend, then Deepa will attend too. If Bharani does not attend, then Akash will not attend....
1 1 vote
2 2 answers
831
831 views
In a running race, Geetha finishes ahead of Shalini and Vani finishes after Aparna. Divya finishes ahead of Aparna. Which of the following is a minimal set of additional ...
7 7 votes
3 3 answers
1.3k
1.3k views
Let $G=(V, E)$ be an undirected simple graph, and $s$ be a designated vertex in $G.$ For each $v\in V,$ let $d(v)$ be the length of a shortest path between $s$ and $v.$ ...
2 2 votes
2 2 answers
1.1k
1.1k views
How many paths are there in the plane from $(0,0)$ to $(m,n)\in \mathbb{N}\times \mathbb{N},$ if the possible steps from $(i,j)$ are either $(i+1,j)$ or $(i,j+1)?$$\binom...
3 3 votes
2 answers 2 answers
1.3k
1.3k views
You are given two coins $A$ and $B$ that look identical. The probability that coin $A$ turns up heads is $\frac{1}{4}$, while the probability that coin $B$ turns up heads...
6 6 votes
2 2 answers
932
932 views
Let $C_{n}$ be the number of strings $w$ consisting of $n$ $X's$ and $n$ $Y's$ such that no initial segment of $w$ has more $Y's$ than $X's.$ Now consider the following p...
5 5 votes
2 2 answers
1.4k
1.4k views
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 ...
2 2 votes
1 1 answer
1.3k
1.3k views
Your college has sent a contingent to take part in a cultural festival at a neighbouring institution. Several team events are part of the programme. Each event takes plac...
4 4 votes
3 3 answers
1.6k
1.6k views
What does the following function compute in terms of $n$ and $d$, for integer value of $n$ and $d,d>1?$ Note that $a//b$ denotes the quotient(integer part) of $a \div b,$...
1 1 vote
2 2 answers
1.0k
1.0k views
Consider the following non-deterministic finite automata(NFA) $A_{1}$ and $A_{2}:$Give an example of a word which is accepted by both $A_{1}$ and $A_{2}.$Give an example ...
0 0 votes
2 2 answers
889
889 views
A student requests a recommendation letter from a professor. The professor gives three sealed envelopes. Each envelope contains either a good recommendation letter or a b...
2 2 votes
2 2 answers
1.2k
1.2k views
Let $G$ be a simple graph on $n$ vertices.Prove that if $G$ has more than $\binom{n-1}{2}$ edges then $G$ is connected.For every $n>2$, find a graph $G_{n}$ which has exa...
2 2 votes
2 2 answers
913
913 views
You are given a sorted array of $n$ elements which has been circularly shifted. For example, $\{35,42,5,12,23,26\}$ is a sorted array that has been circularly shifted by ...
1 1 vote
1 1 answer
772
772 views
Let $G=(V,E)$ be an undirected graph and $V=\{1,2,\cdots,n\}.$ The input graph is given to you by a $0-1$ matrix $A$ of size $n\times n$ as follows. For any $1\leq i,j\...
1 1 vote
2 2 answers
1.1k
1.1k views
You are playing an old-style video game in which you have to shoot down alien spaceships as they fly across the screen from left to right. Each spaceship flies across the...
2 2 votes
3 3 answers
1.5k
1.5k views
A First In First Out queue is a data structure supporting the operation Enque, Deque, Print, Enque(x) adds the item $x$ to the tail of the queue. Deque removes the elemen...
To see more, click for the full list of questions or popular tags.