GATE 2006 Computer Science and Information Technology (CS) Questions with Solutions

GATE 2006

191 questions

MCQ 1911-mark 191

Questions 46–50 of 191

Q46Discrete Mathematics1 markMCQ−0.33 if wrong
A set X can be represented by an array x[n] as follows
x[i]={1ifi∈X0otherwisex[i]=\left\{\begin{matrix} 1 &if i\in X \\ 0& otherwise \end{matrix}\right.
Consider the following algorithm in which x,y and z are boolean arrays of size n;
algorithm zzz(x[] , y[], z [])
{
   int i;
   for (i=O; i < n; ++i)
         z[i] = (x[i] ^ ~y[i]) V (~x[i] ^ y[i])
}
The set Z computed by the algorithm is

Q47Discrete Mathematics1 markMCQ−0.33 if wrong
Let T be a depth first search tree in a undirected graph G Vertices u and v are leaves of this tree T. The degrees of both u and v in G are at least 2. Which one of the following statements is true?

Q48Discrete Mathematics1 markMCQ−0.33 if wrong
Let SHAM3 be the problem of finding a Hamiltonian cycle in a graph G=(V,E) with |V| divisible by 3 and DHAM3 be the problem of determining if a Hamltonian cycle exists in such graphs. Which one of the following is true?

Q49Discrete Mathematics1 markMCQ−0.33 if wrong
Consider the following propositional statements:
P1:((A∧B)→C)≡(A→C)∧(B→C)P1:((A\wedge B)\rightarrow C)\equiv (A\rightarrow C)\wedge (B\rightarrow C)
P2:((A∨B)→C)≡(A→C)∨(B→C)P2:((A\vee B)\rightarrow C)\equiv (A\rightarrow C)\vee (B\rightarrow C)
Which one of the following is true?

Q50Discrete Mathematics1 markMCQ−0.33 if wrong
Which one of the first order predicate calculus statements given below correctly expresses the following English statement?

Tigers and lions attack if they are hungry or threatened.