# CMI2017-A-03

443 views

Four siblings go shopping with their father. If Abhay gets shoes, then Asha does not get a necklace. If Arun gets a T-shirt, then Aditi gets bangles. If Abhay does not get shoes or Aditi gets bangles, the mother will be happy. Which of the following is TRUE?

1. If the mother is happy, then Aditi got bangles.
2. If Aditi got bangles, then Abhay got shoes.
3. If the mother is not happy, then Asha did not get a necklace and Arun did not get a T-shirt.
4. None of the above.

edited

Let's name the events:

$\mathbf{S}$ = Abhay gets shoes

$\mathbf{N}$ = Asha gets a necklace

$\mathbf{T}$ = Arun gets a T-shirt

$\mathbf{B}$ = Aditi gets bangles

$\mathbf{M}$ = Mother is happy.

Now understanding the questions in a logical way:

NOTE: "if p, then q" is equivalent to writing: $p \rightarrow \ q$

If Abhay gets shoes, then Asha does not get a necklace.

This can be written as:

$\mathbf{S \rightarrow \ \sim N }$

If Arun gets a T-shirt, then Aditi gets bangles.

$\mathbf{T \rightarrow \ B }$

If Abhay does not get shoes or Aditi gets bangles, the mother will be happy.

$\mathbf{(\sim S \vee B) \rightarrow \ M }$

We have to see that what can be inferred from these three statements.

Now looking at the options:

1. If the mother is happy, then Aditi got bangles.
$M \rightarrow \ B$
This can not be inferred because it might be the case that Aditi does not get bangles, but the mother is still happy.

2. If Aditi got bangles, then Abhay got shoes.
$B \rightarrow \ S$
This also can not be inferred. It can be that Aditi got bangles, but Abhay does not get shoes.

3. If the mother is not happy, then Asha did not get a necklace and Arun did not get a T-shirt.
$\sim M \rightarrow \ (\sim N \ \wedge \sim T)$
This can be inferred as follows:
We have: $(\sim S \vee B) \rightarrow \ M$
Contrapositive of this is: $\sim M \rightarrow \ \sim (\sim S \vee B)$
$\ \ =\ \sim M \rightarrow \ (S \wedge \sim B)$    ----- $(1)$
We also have: $S \rightarrow \ \sim N$ ----- $(2)$,
And: $T \rightarrow \ B$
whose contrapositive is: $\sim B \rightarrow \ \sim T$ ----- $(3)$
From $(1), (2)$ and $(3)$ we can conclude:
$\sim M \rightarrow \ (\sim N \ \wedge \sim T)$

Hence, the correct option should be (C)

edited by
0
didnt get C part ## Related questions

1
962 views
We have constructed a polynomial time reduction from problem $A$ to problem $B$. Which of the following is a valid inference? If the best algorithm for $B$ takes exponential time, then there is no polynomial time algorithm for $A$ If the best algorithm for $A$ takes ... If we don't know whether there is a polynomial time algorithm for $B$, then there cannot be a polynomial time algorithm for $A$.
1 vote
Suppose we constructed the binary search tree shown below by starting with an empty tree and inserting one element at a time from an input sequence, without any rotations or other manipulations. Which of the following assertions about the order of elements in the input sequence $cannot$ be true? $8$ ... $1$ came after $12$ and $29$ came before $42$. $3$ came before $14$ and $16$ came before $28$.
A $\text{stable sort}$ preserves the order of values that are equal with respect to the comparison function. We have a list of three-dimensional points $[(7, 1, 8),(3, 5, 7),(6, 1, 4),(6, 5, 9),(0, 2, 5),(9, 0, 9)].$ We sort these in ascending order by the second coordinate. Which of the following corresponds to a ... $[(9, 0, 9),(6, 1, 4),(7, 1, 8),(0, 2, 5),(3, 5, 7),(6, 5, 9)]$
Consider the following functions f() and g(). f(){ g(){ w=5; z=w+1; w=2*z+2; z=3*z-w; } print(z); } We start with $w$ and $z$ set to $0$ and execute $f()$ and $g()$ in parallel—that is, at each step we either execute one statement from $f()$ or one statement from $g()$. Which of the following is not a possible value printed by $g()$ ? $-2$ $-1$ $2$ $4$